[CMake] CMAKE_SOURCE_DIR overwritten by CMake Fortran language support

Arjen Markus arjen.markus at deltares.nl
Mon Mar 29 02:58:40 EDT 2010


Hi Alan,

I have no time today to really dig into the output, but while
CMAKE_HOMEDIRECTORY points to the right directory, the outcome is
the same: the "wrong" information file gets loaded.

I will send the detailed output from cmake --trace in a separate
mail (> 0.5 MB).

Regards,

Arjen

On 2010-03-26 22:20, Alan W. Irwin wrote:
> On 2010-03-26 16:44-0400 Brad King wrote:
> 
>> 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());
> 
> What does this->GetHomeDirectory() do?
> 
> Arjen reported to me that CMAKE_SOURCE_DIR was overwritten to
> F:/plplot-svn/build-mingw-test-cmake/language_tests/Fortran/CMakeFiles/CMakeTmp/ 
> 
> 
> Is that consistent with the above code in the MinGW case?
> 
>>> 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.
> 
> In case Arjen is slow to respond with results from cmake --trace, I hope 
> the
> additional information above gives you some help in tracking this down.
> 
> Alan
> __________________________
> Alan W. Irwin
> 
> Astronomical research affiliation with Department of Physics and Astronomy,
> University of Victoria (astrowww.phys.uvic.ca).
> 
> Programming affiliations with the FreeEOS equation-of-state implementation
> for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
> package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
> Linux Links project (loll.sf.net); and the Linux Brochure Project
> (lbproject.sf.net).
> __________________________
> 
> Linux-powered Science
> __________________________
> 


More information about the CMake mailing list