[Cmake] Determining host compiler/OS from CMake

Andy Cedilnik Andy.Cedilnik at kitware.com
Mon Mar 4 18:18:29 EST 2002


I like this.

                 Andy

At 06:07 PM 3/4/2002 -0500, William A. Hoffman wrote:
>Seems a bit too specific.   You can do the same with an IF statement.
>You may want to add the flags to one file for another reason than the type 
>of compiler.
>
>I guess we could have something like this:
>
>SOURCE_FILES_FLAGS("-flag -flag2" file1 file2 VARIABLE)
>Where VARIABLE is optional, but if present and true then the flags are added.
>So you could do:
>SOURCE_FILES_FLAGS("-flag -flag2" file1 file2 CMAKE_COMPILER_IS_GNUCXX)





More information about the CMake mailing list