[CMake] Making with purify

Eric Bolz ebolz at mitre.org
Wed Oct 13 15:52:26 EDT 2004


In Mastering CMake, page 56, the example for building a purify version 
works fine but sometimes I want to build with purify and sometimes I 
don't.  How is that done?  I can do the following:
ADD_EXECUTABLE(my_exe  etc...)
SET(CMAKE_C_LINK_EXECUTABLE "purify  etc...")  as per the example on page 56
ADD_EXECUTABLE(my_exe.purify  etc...)

But now my makefile produces both the purify and non-purify executables 
every time.
I just want to type 'make' to build my regular executable and I want to 
type 'make purify' when I want the purified version.  Can this be done?



More information about the CMake mailing list