ccache selects wrong compiler (calls clang, not gcc46)

Beeblebrox zaphod at berentweb.com
Mon Jan 7 19:37:45 UTC 2013


I have a clang-only world (no gcc42) and want to use gcc46 for port building.
I have ccache and distcc installed. In /etc/make.conf I have:

CC:=${CC:C,^gcc46,/usr/local/libexec/ccache/world/gcc46,1}
CXX:=${CXX:C,^g\+\+\46,/usr/local/libexec/ccache/world/g++46,1}

This used to work correctly but does not anymore. Compiler keeps insisting
on using clang and during portbuild I get below output. Note that I have
distcc disabled at the moment, but distcc gets called anyway.

distcc[11685] (dcc_build_somewhere) Warning: failed to distribute, running
locally instead
/usr/local/bin/ccache /usr/local/bin/distcc g++46 -c -pipe -g
-D__STDC_FORMAT_MACROS -Wno-unused-parameter -O2 -pipe -march=k8
-fno-strict-aliasing -fPIC -Wall -W  ... etc

I have traced the problem to the ccache pre-compiler because in
/etc/make.conf if I replace above with:
CC=gcc46
CXX=g++46
distcc and ccache still get called (but not clang) unless I also enable:
CPP=cpp46




--
View this message in context: http://freebsd.1045724.n5.nabble.com/ccache-selects-wrong-compiler-calls-clang-not-gcc46-tp5775609.html
Sent from the freebsd-ports mailing list archive at Nabble.com.


More information about the freebsd-ports mailing list