tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: c++11



On 11/03/2016 07:56, Thomas Klausner wrote:
Hi!

Currently, when a package needs C++11, we set

CXXFLAGS+= -std=c++11

and hope for the best, i.e. that the platform compiler supports this.

Shouldn't we rather add support to USE_LANGUAGES like this:

USE_LANGUAGES+=	c++11

and make bsd.pkg.mk set CXXFLAGS and request a good-enough compiler?
  Thomas

I agree. I run into this with a lot of scientific software and specifying a compiler in the pkg is kludgy. I assume people are aware of how FreeBSD ports handles this (e.g. USES+=compiler:c++11-lang). That system has some limitations, but at least it's compiler-agnostic and provides an interface that can remain consistent as the compiler landscape changes.

Cheers,

    Jason



Home | Main Index | Thread Index | Old Index