diff options
author | Robert Goulet <robert.goulet@autodesk.com> | 2015-09-23 21:15:29 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-09-24 13:13:03 (GMT) |
commit | bd189cc24e2292ab80dde7c0d0ac1cd9fafb2d35 (patch) | |
tree | 27ffc539451f22c4aff837ba8d5b26e97d52ad98 /Tests | |
parent | 69ab5f55026c7e884a70f04aa7ddef776f74305b (diff) | |
download | CMake-bd189cc24e2292ab80dde7c0d0ac1cd9fafb2d35.zip CMake-bd189cc24e2292ab80dde7c0d0ac1cd9fafb2d35.tar.gz CMake-bd189cc24e2292ab80dde7c0d0ac1cd9fafb2d35.tar.bz2 |
install: Allow generator expressions in DIRECTORY DESTINATION
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/ExportImport/Export/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-result.txt | 1 | ||||
-rw-r--r-- | Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-stderr.txt | 6 | ||||
-rw-r--r-- | Tests/RunCMake/install/DIRECTORY-DESTINATION-bad.cmake | 1 | ||||
-rw-r--r-- | Tests/RunCMake/install/RunCMakeTest.cmake | 1 | ||||
-rw-r--r-- | Tests/SimpleInstall/CMakeLists.txt | 6 | ||||
-rw-r--r-- | Tests/SimpleInstallS2/CMakeLists.txt | 6 |
7 files changed, 16 insertions, 7 deletions
diff --git a/Tests/ExportImport/Export/CMakeLists.txt b/Tests/ExportImport/Export/CMakeLists.txt index 1e52a09..a3f1f81 100644 --- a/Tests/ExportImport/Export/CMakeLists.txt +++ b/Tests/ExportImport/Export/CMakeLists.txt @@ -551,5 +551,5 @@ install( ARCHIVE DESTINATION lib INCLUDES DESTINATION include/abs ) -install(DIRECTORY include/abs DESTINATION include) +install(DIRECTORY include/abs DESTINATION $<1:include>$<0:/wrong>) install(EXPORT expAbs NAMESPACE expAbs_ DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/expAbs) diff --git a/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-result.txt b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-stderr.txt b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-stderr.txt new file mode 100644 index 0000000..9844158 --- /dev/null +++ b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad-stderr.txt @@ -0,0 +1,6 @@ +CMake Error: + Error evaluating generator expression: + + \$<NOTAGENEX> + + Expression did not evaluate to a known generator expression diff --git a/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad.cmake b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad.cmake new file mode 100644 index 0000000..f050cdf --- /dev/null +++ b/Tests/RunCMake/install/DIRECTORY-DESTINATION-bad.cmake @@ -0,0 +1 @@ +install(DIRECTORY dir DESTINATION $<NOTAGENEX>) diff --git a/Tests/RunCMake/install/RunCMakeTest.cmake b/Tests/RunCMake/install/RunCMakeTest.cmake index 2ce0095..043bd1f 100644 --- a/Tests/RunCMake/install/RunCMakeTest.cmake +++ b/Tests/RunCMake/install/RunCMakeTest.cmake @@ -6,6 +6,7 @@ run_cmake(DIRECTORY-message-lazy) run_cmake(SkipInstallRulesWarning) run_cmake(SkipInstallRulesNoWarning1) run_cmake(SkipInstallRulesNoWarning2) +run_cmake(DIRECTORY-DESTINATION-bad) run_cmake(FILES-DESTINATION-bad) run_cmake(TARGETS-DESTINATION-bad) run_cmake(CMP0062-OLD) diff --git a/Tests/SimpleInstall/CMakeLists.txt b/Tests/SimpleInstall/CMakeLists.txt index 3227e3f..e365076 100644 --- a/Tests/SimpleInstall/CMakeLists.txt +++ b/Tests/SimpleInstall/CMakeLists.txt @@ -252,7 +252,7 @@ else() file(REMOVE_RECURSE "${CMAKE_INSTALL_PREFIX}/MyTest/share/CVS") file(REMOVE_RECURSE "${CMAKE_INSTALL_PREFIX}/MyTest/share/TestSubDir/CVS") install( - DIRECTORY TestSubDir scripts/ DESTINATION MyTest/share + DIRECTORY TestSubDir scripts/ DESTINATION $<1:MyTest/share>$<0:/wrong> FILE_PERMISSIONS OWNER_READ OWNER_WRITE DIRECTORY_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE @@ -263,14 +263,14 @@ else() # Alternate directory installation for coverage. install( - DIRECTORY scripts/ DESTINATION MyTest/share/alt + DIRECTORY scripts/ DESTINATION $<1:MyTest/share/alt>$<0:/wrong> COMPONENT Development USE_SOURCE_PERMISSIONS PATTERN "CVS" EXCLUDE REGEX "\\.txt$" EXCLUDE ) install( - DIRECTORY TestSubDir DESTINATION MyTest/share/alt + DIRECTORY TestSubDir DESTINATION $<1:MyTest/share/alt>$<0:/wrong> FILE_PERMISSIONS OWNER_READ OWNER_WRITE DIRECTORY_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE diff --git a/Tests/SimpleInstallS2/CMakeLists.txt b/Tests/SimpleInstallS2/CMakeLists.txt index 3227e3f..e365076 100644 --- a/Tests/SimpleInstallS2/CMakeLists.txt +++ b/Tests/SimpleInstallS2/CMakeLists.txt @@ -252,7 +252,7 @@ else() file(REMOVE_RECURSE "${CMAKE_INSTALL_PREFIX}/MyTest/share/CVS") file(REMOVE_RECURSE "${CMAKE_INSTALL_PREFIX}/MyTest/share/TestSubDir/CVS") install( - DIRECTORY TestSubDir scripts/ DESTINATION MyTest/share + DIRECTORY TestSubDir scripts/ DESTINATION $<1:MyTest/share>$<0:/wrong> FILE_PERMISSIONS OWNER_READ OWNER_WRITE DIRECTORY_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE @@ -263,14 +263,14 @@ else() # Alternate directory installation for coverage. install( - DIRECTORY scripts/ DESTINATION MyTest/share/alt + DIRECTORY scripts/ DESTINATION $<1:MyTest/share/alt>$<0:/wrong> COMPONENT Development USE_SOURCE_PERMISSIONS PATTERN "CVS" EXCLUDE REGEX "\\.txt$" EXCLUDE ) install( - DIRECTORY TestSubDir DESTINATION MyTest/share/alt + DIRECTORY TestSubDir DESTINATION $<1:MyTest/share/alt>$<0:/wrong> FILE_PERMISSIONS OWNER_READ OWNER_WRITE DIRECTORY_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE |