diff options
author | Stephen Kelly <steveire@gmail.com> | 2013-05-22 08:25:27 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2013-05-24 13:35:43 (GMT) |
commit | 015309fc9f87babaadc2510eb80298b1f2389e8c (patch) | |
tree | 99779cfdb503f98a6ed3c9535a964b3742eabeaa /Tests/CompileDefinitions/add_definitions_command | |
parent | 6aba97642737873921f312e0bbaf18edfabf6e6f (diff) | |
download | CMake-015309fc9f87babaadc2510eb80298b1f2389e8c.zip CMake-015309fc9f87babaadc2510eb80298b1f2389e8c.tar.gz CMake-015309fc9f87babaadc2510eb80298b1f2389e8c.tar.bz2 |
Tests/CompileDefinitions: Avoid spaces in defines on VS 6
The VS 6 IDE does not like spaces in definition values so CMake drops
them and warns. The Tests/CompileDefinitions test C code that looks for
the dropped definitions already knows to skip them, but CMake still
warns. Silence the warnings by avoiding such values in the first place
on VS 6.
Diffstat (limited to 'Tests/CompileDefinitions/add_definitions_command')
-rw-r--r-- | Tests/CompileDefinitions/add_definitions_command/CMakeLists.txt | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/Tests/CompileDefinitions/add_definitions_command/CMakeLists.txt b/Tests/CompileDefinitions/add_definitions_command/CMakeLists.txt index d3886a1..23e0134 100644 --- a/Tests/CompileDefinitions/add_definitions_command/CMakeLists.txt +++ b/Tests/CompileDefinitions/add_definitions_command/CMakeLists.txt @@ -1,8 +1,15 @@ project(add_definitions_command) -add_definitions(-DCMAKE_IS_FUN -DCMAKE_IS=Fun -DCMAKE_IS_="Fun" -DCMAKE_IS_REALLY="Very Fun") -add_definitions(-DCMAKE_IS_="Fun" -DCMAKE_IS_REALLY="Very Fun" -DCMAKE_IS_FUN -DCMAKE_IS=Fun) +add_definitions(-DCMAKE_IS_FUN -DCMAKE_IS=Fun -DCMAKE_IS_="Fun") +if (NOT NO_SPACES_IN_DEFINE_VALUES) + add_definitions(-DCMAKE_IS_REALLY="Very Fun") +endif() +add_definitions(-DCMAKE_IS_="Fun") +if (NOT NO_SPACES_IN_DEFINE_VALUES) + add_definitions(-DCMAKE_IS_REALLY="Very Fun") +endif() +add_definitions(-DCMAKE_IS_FUN -DCMAKE_IS=Fun) add_definitions(-DBUILD_IS_DEBUG=$<CONFIG:Debug> -DBUILD_IS_NOT_DEBUG=$<NOT:$<CONFIG:Debug>>) add_executable(add_definitions_command_executable ../compiletest.cpp) |