setting CC/CXX/CPP unconditionally in src.conf

Dimitry Andric dim at FreeBSD.org
Sun Feb 26 22:52:49 UTC 2012


On 2012-02-26 23:38, Warner Losh wrote:
> On Feb 26, 2012, at 2:37 PM, Alexander Best wrote:
>> any chance support for setting CC/CXX/CPP unconditionally in src.conf could be
>> added before the release of freebsd 10.0? the way it is done atm is really not
>> intuitive. the rule should really be:
>>
>> - make.conf = applies globally
>> - src.conf  = applies only to /usr/src
>> ( maybe a ports.conf or port.conf could be introduced at some point, too)
>> ... the current situation, where only certain variables can be set in src.conf
>> is not ideal.
> 
> What doesn't work?  Or rather, how does it work now?

Setting CC/CXX/CPP and such in src.conf doesn't work, at least not for
all Makefiles in world.  There are still many of them that don't do the
right thing, picking up CC values from sys.mk and/or make.conf instead.

The trickiest one is Makefile.inc1, which does some special magic, and
isn't really a normal BSD Makefile anyway. :)

I've got a git branch with some experiments to have all the compiler
settings read from src.conf instead of make.conf, but I didn't finish it
before some other work took precedence...


More information about the freebsd-toolchain mailing list