[CMake] Project and specific variables

Alan W. Irwin irwin at beluga.phys.uvic.ca
Wed Aug 1 11:09:11 EDT 2007


On 2007-08-01 08:45-0400 Bill Hoffman wrote:

> Alexander.Camek at elektrobit.com wrote:
>> Hi List,
>> 
>> I had a discussion last time and the topic of the discussion was 
>> following: 
>> When you use PROJECT, you normally get the two variablse 
>> <PROJECT_NAME>_SOURCE_DIR and <PROJECT_NAME>_BINARY_DIR.
>> As I got informed these both varibales are only used for backward 
>> compatibility and shall not be used anymore.
>> Instead of that someone may use CMAKE_CURRENT_SOURCE_DIR.
>> 
>> Can somebody tell me if that's right or can the project variables used?
>> 
> Those variables are not going away as far as I know.   I am not sure who 
> informed you of that, but they were wrong.

I will 'fess up here.  :-) I have never used <PROJECT_NAME>_SOURCE_DIR and
<PROJECT_NAME>_BINARY_DIR but they are well documented so I should have
easily found them but didn't.  My problem was I was looking for an exact
match of MAIN_BINARY_DIR and MAIN_SOURCE_DIR (Alexander's project name was
MAIN), but you should never try exact matches.  Live and learn.

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