summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2011-09-23 15:04:15 (GMT)
committerBrad King <brad.king@kitware.com>2011-09-23 15:07:24 (GMT)
commit3b5256e19e27794ba871b0149f4c8f0237d1e872 (patch)
tree4330eec37519bfc68d92c37986dd6bb616142482
parent3d5632ed59d3d46298304d20d3f11f9d1da02f93 (diff)
downloadCMake-3b5256e19e27794ba871b0149f4c8f0237d1e872.zip
CMake-3b5256e19e27794ba871b0149f4c8f0237d1e872.tar.gz
CMake-3b5256e19e27794ba871b0149f4c8f0237d1e872.tar.bz2
Teach our tests about special cases for VS 11
Teach the CheckCompilerRelatedVariables test to verify MSVC11. Update the special cases already in the Preprocess and VSExternalInclude tests for VS 10 to work for VS 11 too.
-rw-r--r--Tests/CheckCompilerRelatedVariables/CMakeLists.txt4
-rw-r--r--Tests/Preprocess/CMakeLists.txt5
-rw-r--r--Tests/VSExternalInclude/CMakeLists.txt4
3 files changed, 10 insertions, 3 deletions
diff --git a/Tests/CheckCompilerRelatedVariables/CMakeLists.txt b/Tests/CheckCompilerRelatedVariables/CMakeLists.txt
index 8095a1c..8b279a5 100644
--- a/Tests/CheckCompilerRelatedVariables/CMakeLists.txt
+++ b/Tests/CheckCompilerRelatedVariables/CMakeLists.txt
@@ -34,6 +34,9 @@ endif()
if(DEFINED MSVC10)
math(EXPR msvc_total "${msvc_total} + 1")
endif()
+if(DEFINED MSVC11)
+ math(EXPR msvc_total "${msvc_total} + 1")
+endif()
echo_var(MSVC)
echo_var(MSVC60)
@@ -42,6 +45,7 @@ echo_var(MSVC71)
echo_var(MSVC80)
echo_var(MSVC90)
echo_var(MSVC10)
+echo_var(MSVC11)
if(MSVC)
#
diff --git a/Tests/Preprocess/CMakeLists.txt b/Tests/Preprocess/CMakeLists.txt
index b4ec17c..1ed7b83 100644
--- a/Tests/Preprocess/CMakeLists.txt
+++ b/Tests/Preprocess/CMakeLists.txt
@@ -37,6 +37,9 @@ endif("${CMAKE_GENERATOR}" MATCHES "Visual Studio")
if("${CMAKE_GENERATOR}" MATCHES "Visual Studio 10")
set(PP_VS100 1)
endif("${CMAKE_GENERATOR}" MATCHES "Visual Studio 10")
+if("${CMAKE_GENERATOR}" MATCHES "Visual Studio 11")
+ set(PP_VS110 1)
+endif("${CMAKE_GENERATOR}" MATCHES "Visual Studio 11")
# Some tests below check the PP_* variables set above. They are meant
# to test the case that the build tool is at fault. Other tests below
@@ -52,7 +55,7 @@ endif("${CMAKE_GENERATOR}" MATCHES "Visual Studio 10")
# must not have it escaped inside the configured header.
set(STRING_EXTRA "")
-if(NOT BORLAND AND NOT PP_VS70 AND NOT PP_VS100)
+if(NOT BORLAND AND NOT PP_VS70 AND NOT PP_VS100 AND NOT PP_VS110)
# Borland, VS70 IDE: ;
# The Borland compiler will simply not accept a non-escaped semicolon
# on the command line. If it is escaped \; then the escape character
diff --git a/Tests/VSExternalInclude/CMakeLists.txt b/Tests/VSExternalInclude/CMakeLists.txt
index 1e68968..a2fd619 100644
--- a/Tests/VSExternalInclude/CMakeLists.txt
+++ b/Tests/VSExternalInclude/CMakeLists.txt
@@ -6,7 +6,7 @@ IF(${CMAKE_GENERATOR} MATCHES "Visual Studio 6")
ELSE(${CMAKE_GENERATOR} MATCHES "Visual Studio 6")
SET(PROJECT_EXT vcproj)
ENDIF(${CMAKE_GENERATOR} MATCHES "Visual Studio 6")
-IF(${CMAKE_GENERATOR} MATCHES "Visual Studio 10")
+IF(${CMAKE_GENERATOR} MATCHES "Visual Studio 1[01]")
SET(PROJECT_EXT vcxproj)
ENDIF()
@@ -46,7 +46,7 @@ ADD_DEPENDENCIES(VSExternalInclude lib2)
# and the sln file can no longer be the only source
# of that depend. So, for VS 10 make the executable
# depend on lib1 and lib2
-IF(MSVC10)
+IF(MSVC10 OR MSVC11)
ADD_DEPENDENCIES(VSExternalInclude lib1)
ENDIF()