summaryrefslogtreecommitdiffstats
path: root/Tests/SimpleInstallS2
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/SimpleInstallS2')
-rw-r--r--Tests/SimpleInstallS2/CMakeLists.txt16
1 files changed, 16 insertions, 0 deletions
diff --git a/Tests/SimpleInstallS2/CMakeLists.txt b/Tests/SimpleInstallS2/CMakeLists.txt
index 461280d..c2de5b1 100644
--- a/Tests/SimpleInstallS2/CMakeLists.txt
+++ b/Tests/SimpleInstallS2/CMakeLists.txt
@@ -72,6 +72,14 @@ IF(STAGE2)
MESSAGE(SEND_ERROR "test1 not found in lib/static!")
ENDIF("${TEST1_LIBRARY}" MATCHES "static")
+ # Check for failure of configuration-specific installation.
+ IF(EXISTS "${CMAKE_INSTALL_PREFIX}/MyTest/include/Release/lib1debug.h")
+ MESSAGE(FATAL_ERROR "Debug-configuration file installed for Release!")
+ ENDIF(EXISTS "${CMAKE_INSTALL_PREFIX}/MyTest/include/Release/lib1debug.h")
+ IF(EXISTS "${CMAKE_INSTALL_PREFIX}/MyTest/include/Debug/lib1release.h")
+ MESSAGE(FATAL_ERROR "Release-configuration file installed for Debug!")
+ ENDIF(EXISTS "${CMAKE_INSTALL_PREFIX}/MyTest/include/Debug/lib1release.h")
+
# Make sure the test executable can run from the install tree.
SET_TARGET_PROPERTIES(SimpleInstallS2 PROPERTIES
INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/MyTest/lib)
@@ -122,6 +130,14 @@ ELSE(STAGE2)
)
INSTALL_FILES(/MyTest/include FILES lib3.h)
+ # Test configuration-specific installation.
+ INSTALL(FILES lib1.h RENAME lib1release.h CONFIGURATIONS Release
+ DESTINATION MyTest/include/Release
+ )
+ INSTALL(FILES lib1.h RENAME lib1debug.h CONFIGURATIONS Debug
+ DESTINATION MyTest/include/Debug
+ )
+
# Test user-specified install scripts.
INSTALL(
SCRIPT InstallScript1.cmake