summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeLists.txt
diff options
context:
space:
mode:
authorManuel Klimek <klimek@google.com>2011-04-25 17:16:01 (GMT)
committerBrad King <brad.king@kitware.com>2011-05-16 14:42:10 (GMT)
commit8346a28a0a6587382a30d06a998ae83caa574f4b (patch)
tree2420195b95df0d2691b830585ccdbd0b9153de1e /Tests/CMakeLists.txt
parent0e6b05fcba61a1b113b841dd2b3e1e5060866d0e (diff)
downloadCMake-8346a28a0a6587382a30d06a998ae83caa574f4b.zip
CMake-8346a28a0a6587382a30d06a998ae83caa574f4b.tar.gz
CMake-8346a28a0a6587382a30d06a998ae83caa574f4b.tar.bz2
Only offer the compile command output feature on unix systems
Diffstat (limited to 'Tests/CMakeLists.txt')
-rw-r--r--Tests/CMakeLists.txt10
1 files changed, 8 insertions, 2 deletions
diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt
index 126eadd..2344af7 100644
--- a/Tests/CMakeLists.txt
+++ b/Tests/CMakeLists.txt
@@ -39,6 +39,10 @@ CONFIGURE_FILE(${CMake_SOURCE_DIR}/Tests/EnforceConfig.cmake.in
# Testing
IF(BUILD_TESTING)
+ IF("${CMAKE_TEST_GENERATOR}" MATCHES "Unix Makefiles")
+ SET(TEST_CompileCommandOutput 1)
+ ENDIF()
+
ADD_SUBDIRECTORY(CMakeLib)
# Collect a list of all test build directories.
@@ -2032,8 +2036,10 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/
SET_TESTS_PROPERTIES(Contracts.${project} PROPERTIES TIMEOUT ${timeout})
ENDFOREACH()
- ADD_TEST_MACRO(CompileCommandOutput
- "${CMake_BINARY_DIR}/Tests/CMakeLib/runcompilecommands")
+ IF(TEST_CompileCommandOutput)
+ ADD_TEST_MACRO(CompileCommandOutput
+ "${CMake_BINARY_DIR}/Tests/CMakeLib/runcompilecommands")
+ ENDIF()
ENDIF(BUILD_TESTING)
SUBDIRS(CMakeTests)