[CMake] Does CMake 3.3.1 ignore CXX env variable on OSX10.10?

Nils Gladitz nilsgladitz at gmail.com
Tue Sep 22 13:17:54 EDT 2015


On 22.09.2015 17:53, Pere Mato Vila wrote:
> Thanks Nils. This explains it. So, the value of CXX is not honored.

I wouldn't go that far given that /usr/bin/clang++ and cmake call the 
same compiler.
If you were to use a compiler in a custom installation prefix (without 
apple's tool in between) and would pass that to CXX the compiler would 
be used as-is.

CXX is honored even if the path is not preserved.

> The problem we have, is that we record the compiler that we have used to build for runtime usage. If we make a binary distribution, this one will we used by clients that may have the compiler somewhere else.

Given that /usr/bin/clang++ on the build system and /usr/bin/clang++ on 
a client system may not actually call the same compilers does it even 
make sense to record and use it as-is?

Nils


More information about the CMake mailing list