[CMake] Overriding read-only project's CMakeLists.txt

Kenneth Porter shiva at sewingwitch.com
Tue Dec 29 12:00:47 EST 2009


--On Tuesday, December 29, 2009 5:55 PM +0100 Michael Wild 
<themiwi at gmail.com> wrote:

> Have a look at the -C option which allows you to set cache variables
> before anything else runs. You can use that in a batch script to set up
> things automatically.

My initial attempt at that used John's example of if(MSVC) but I'm guessing 
that file can't use anything but simple variable assignments.

> And it's not CMAKE_<target>_PREFIX you want (no such variable, except
> CMAKE_INSTALL_PREFIX, which is probably not what you meant), but
> CMAKE_<CONFIG>_POSTFIX, where <CONFIG> is Debug, Release, RelWithDebInfo,
> MinSizeRel and any other configuration the project lists in
> CMAKE_CONFIGURATION_TYPES.

Doh, you're right. Typo while transcribing.


More information about the CMake mailing list