[CMake] CMAKE_SOURCE_DIR overwritten by CMake Fortran language support
Brad King
brad.king at kitware.com
Fri Mar 26 16:44:49 EDT 2010
Bill Hoffman wrote:
> Alan W. Irwin wrote:
>> It has been reported (by Arjen Markus) that the MinGW issue
>> is because something in that case overwrites CMAKE_SOURCE_DIR
There is only one line in the entire source tree that ever sets
that variable. It's in Source/cmMakefile.cxx:
this->AddDefinition("CMAKE_SOURCE_DIR", this->GetHomeDirectory());
This was true in 2.6.x, 2.8.x, and probably all earlier versions.
Several code paths activate that line though.
> One thing you might want to try is cmake --trace, and then track down
> where the CMAKE_SOURCE_DIR is getting clobbered.
This is a good approach.
-Brad
More information about the CMake
mailing list