diff options
author | Stephen Kelly <steveire@gmail.com> | 2013-11-26 09:39:23 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2013-11-26 12:01:50 (GMT) |
commit | f088a3245001350f9c429e27bd12a3394742b0b8 (patch) | |
tree | e2c5b7c3fad8196d6fc537d1292b6aa676a160ca /Tests/ExportImport/Export | |
parent | 9eedc850eb1419d678bda8137610dba1c289bb6a (diff) | |
download | CMake-f088a3245001350f9c429e27bd12a3394742b0b8.zip CMake-f088a3245001350f9c429e27bd12a3394742b0b8.tar.gz CMake-f088a3245001350f9c429e27bd12a3394742b0b8.tar.bz2 |
Export: Process INSTALL_INTERFACE in INCLUDES DESTINATION.
Code such as
install(TARGETS ...
INCLUDES DESTINATION $<INSTALL_INTERFACE:include>
)
should behave as if the INSTALL_INTERFACE wrapper were not present.
Diffstat (limited to 'Tests/ExportImport/Export')
-rw-r--r-- | Tests/ExportImport/Export/CMakeLists.txt | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/Tests/ExportImport/Export/CMakeLists.txt b/Tests/ExportImport/Export/CMakeLists.txt index 6f48fcc..89c767f 100644 --- a/Tests/ExportImport/Export/CMakeLists.txt +++ b/Tests/ExportImport/Export/CMakeLists.txt @@ -313,6 +313,20 @@ install(TARGETS testLibRequired $<INSTALL_PREFIX>/installIncludesTest2 installIncludesTest3/$<TARGET_PROPERTY:NAME> $<TARGET_PROPERTY:NAME>/installIncludesTest4 + $<INSTALL_INTERFACE:installIncludesTest5$<0:>> + $<INSTALL_INTERFACE:$<0:>installIncludesTest6> + $<INSTALL_INTERFACE:$<INSTALL_PREFIX>/installIncludesTest7> +) + +target_include_directories(testLibRequired INTERFACE + # These can't be in the above install(INCLUDES DESTINATION call because + # that is only for installed interfaces. These directories are prefixes + # in the build dir, which is an error for the installed interface. + # We add them here so that we don't have to add conditions in the Import + # component of the test. + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest5$<0:>> + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/$<0:>installIncludesTest6> + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest7> ) install(TARGETS testLibIncludeRequired1 @@ -340,6 +354,12 @@ file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest3/testLibReq file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest3/testLibRequired/installIncludesTest3.h" "// No content\n") file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/testLibRequired/installIncludesTest4") file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/testLibRequired/installIncludesTest4/installIncludesTest4.h" "// No content\n") +file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest5") +file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest5/installIncludesTest5.h" "// No content\n") +file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest6") +file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest6/installIncludesTest6.h" "// No content\n") +file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest7") +file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest7/installIncludesTest7.h" "// No content\n") install(FILES "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest/installIncludesTest.h" DESTINATION installIncludesTest @@ -356,6 +376,18 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/testLibRequired/installIncludesTest4/installIncludesTest4.h" DESTINATION testLibRequired/installIncludesTest4 ) +install(FILES + "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest5/installIncludesTest5.h" + DESTINATION installIncludesTest5 +) +install(FILES + "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest6/installIncludesTest6.h" + DESTINATION installIncludesTest6 +) +install(FILES + "${CMAKE_CURRENT_BINARY_DIR}/installIncludesTest7/installIncludesTest7.h" + DESTINATION installIncludesTest7 +) install(TARGETS testLibDepends testSharedLibDepends EXPORT DependsExp DESTINATION lib ) install(EXPORT DependsExp FILE testLibDependsTargets.cmake DESTINATION lib/cmake/testLibDepends) |