AW: [CMake] Overriding default values
Sören Freudiger
muffmolch at gmx.de
Fri Sep 2 13:24:37 EDT 2005
May you just set a variable after the first configure by yourself:
CMakeList.txt:
-------------------
IF(NOT PASSED_FIRST_CONFIGURE)
ADD_CXX_COMMAND("/wd4996")
ADD_CXX_COMMAND("/ML")
REMOVE_CXX_COMMAND("/MD")
ENDIF(NOT PASSED_FIRST_CONFIGURE)
...
SET(PASSED_FIRST_CONFIGURE)
--------------
this should work. but I would be happy if there already would be such an
variable odderd by CMake
-----Ursprüngliche Nachricht-----
Von: cmake-bounces+muffmolch=gmx.de at cmake.org
[mailto:cmake-bounces+muffmolch=gmx.de at cmake.org] Im Auftrag von James
Bigler
Gesendet: Freitag, 2. September 2005 19:08
Cc: cmake at cmake.org
Betreff: Re: [CMake] Overriding default values
Perhaps I should be more clear as to what I'm trying to do.
Is there a way to determine if CMake has been configured once for a given
project?
CMake obviously defines defaults for certain variables. For example:
CMAKE_CXX_FLAGS_RELEASE -O2
Now, as the user, I can change this value with ccmake to be whatever I want,
and CMake will not change that ever once it has configured once.
All I want to do is offer a different default option that has the same
properties. Once CMake configures the first time, CMake doesn't touch the
value again.
Thanks,
James
_______________________________________________
CMake mailing list
CMake at cmake.org
http://www.cmake.org/mailman/listinfo/cmake
More information about the CMake
mailing list