diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-04-11 09:31:43 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-04-12 18:08:46 (GMT) |
commit | 6fb306ea3bbe04b8e4dde8f13eec3e6bdfe35086 (patch) | |
tree | 6d92a08a1615b8b2f5443d6bc420f70edba6d02c /Tests | |
parent | 7450a2c6ed601dc94f2de410661065554ff8ce12 (diff) | |
download | CMake-6fb306ea3bbe04b8e4dde8f13eec3e6bdfe35086.zip CMake-6fb306ea3bbe04b8e4dde8f13eec3e6bdfe35086.tar.gz CMake-6fb306ea3bbe04b8e4dde8f13eec3e6bdfe35086.tar.bz2 |
Test expected value of DEBUG_CONFIGURATIONS global property.
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/RunCMake/get_property/DebugConfigurations-stderr.txt | 11 | ||||
-rw-r--r-- | Tests/RunCMake/get_property/DebugConfigurations.cmake | 41 | ||||
-rw-r--r-- | Tests/RunCMake/get_property/RunCMakeTest.cmake | 1 |
3 files changed, 53 insertions, 0 deletions
diff --git a/Tests/RunCMake/get_property/DebugConfigurations-stderr.txt b/Tests/RunCMake/get_property/DebugConfigurations-stderr.txt new file mode 100644 index 0000000..b295604 --- /dev/null +++ b/Tests/RunCMake/get_property/DebugConfigurations-stderr.txt @@ -0,0 +1,11 @@ +CONFIGS: +IFACE1:\$<\$<CONFIG:DEBUG>:external1> +CONFIGS:EXTRA +IFACE1:\$<\$<CONFIG:DEBUG>:external1> +IFACE1:\$<\$<CONFIG:DEBUG>:external1>;\$<\$<CONFIG:EXTRA>:external2> +CONFIGS:NEW;CONFIGS +IFACE1:\$<\$<CONFIG:DEBUG>:external1>;\$<\$<CONFIG:EXTRA>:external2> +IFACE1:\$<\$<CONFIG:DEBUG>:external1>;\$<\$<CONFIG:EXTRA>:external2>;\$<\$<OR:\$<CONFIG:NEW>,\$<CONFIG:CONFIGS>>:external3> +CONFIGS:NEW;CONFIGS;EXTRA +IFACE1:\$<\$<CONFIG:DEBUG>:external1>;\$<\$<CONFIG:EXTRA>:external2>;\$<\$<OR:\$<CONFIG:NEW>,\$<CONFIG:CONFIGS>>:external3> +IFACE1:\$<\$<CONFIG:DEBUG>:external1>;\$<\$<CONFIG:EXTRA>:external2>;\$<\$<OR:\$<CONFIG:NEW>,\$<CONFIG:CONFIGS>>:external3>;\$<\$<OR:\$<CONFIG:NEW>,\$<CONFIG:CONFIGS>,\$<CONFIG:EXTRA>>:external4> diff --git a/Tests/RunCMake/get_property/DebugConfigurations.cmake b/Tests/RunCMake/get_property/DebugConfigurations.cmake new file mode 100644 index 0000000..534beaf --- /dev/null +++ b/Tests/RunCMake/get_property/DebugConfigurations.cmake @@ -0,0 +1,41 @@ + +enable_language(CXX) + +get_property(configs GLOBAL PROPERTY DEBUG_CONFIGURATIONS) +message("CONFIGS:${configs}") + +add_library(iface1 INTERFACE) +target_link_libraries(iface1 INTERFACE debug external1) + +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") + +set_property(GLOBAL APPEND PROPERTY DEBUG_CONFIGURATIONS EXTRA) +get_property(configs GLOBAL PROPERTY DEBUG_CONFIGURATIONS) +message("CONFIGS:${configs}") + +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") +target_link_libraries(iface1 INTERFACE debug external2) +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") + +set_property(GLOBAL PROPERTY DEBUG_CONFIGURATIONS NEW CONFIGS) +get_property(configs GLOBAL PROPERTY DEBUG_CONFIGURATIONS) +message("CONFIGS:${configs}") + +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") +target_link_libraries(iface1 INTERFACE debug external3) +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") + +set_property(GLOBAL APPEND PROPERTY DEBUG_CONFIGURATIONS EXTRA) +get_property(configs GLOBAL PROPERTY DEBUG_CONFIGURATIONS) +message("CONFIGS:${configs}") + +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") +target_link_libraries(iface1 INTERFACE debug external4) +get_property(tgt_iface TARGET iface1 PROPERTY INTERFACE_LINK_LIBRARIES) +message("IFACE1:${tgt_iface}") diff --git a/Tests/RunCMake/get_property/RunCMakeTest.cmake b/Tests/RunCMake/get_property/RunCMakeTest.cmake index 1964824..e420b5b 100644 --- a/Tests/RunCMake/get_property/RunCMakeTest.cmake +++ b/Tests/RunCMake/get_property/RunCMakeTest.cmake @@ -7,3 +7,4 @@ run_cmake(install_properties) run_cmake(source_properties) run_cmake(target_properties) run_cmake(test_properties) +run_cmake(DebugConfigurations) |