diff options
author | Brad King <brad.king@kitware.com> | 2017-08-31 17:04:34 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-08-31 17:10:26 (GMT) |
commit | a47a853376184031051ed744ed4718a69876002d (patch) | |
tree | 52373cfa5c1ac25da037b531233fc89564f7c2b4 /Tests/RunCMake | |
parent | 4f96641ba2e0b26523f962e2c18aa83a8b91c6aa (diff) | |
download | CMake-a47a853376184031051ed744ed4718a69876002d.zip CMake-a47a853376184031051ed744ed4718a69876002d.tar.gz CMake-a47a853376184031051ed744ed4718a69876002d.tar.bz2 |
target_link_libraries: Allow linking to UNKNOWN IMPORTED GLOBAL libs
This combination was accidentally rejected. Allow it and add a test.
Fixes: #17245
Diffstat (limited to 'Tests/RunCMake')
-rw-r--r-- | Tests/RunCMake/target_link_libraries/RunCMakeTest.cmake | 1 | ||||
-rw-r--r-- | Tests/RunCMake/target_link_libraries/UNKNOWN-IMPORTED-GLOBAL.cmake | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/Tests/RunCMake/target_link_libraries/RunCMakeTest.cmake b/Tests/RunCMake/target_link_libraries/RunCMakeTest.cmake index 1466fbf..b1c9435 100644 --- a/Tests/RunCMake/target_link_libraries/RunCMakeTest.cmake +++ b/Tests/RunCMake/target_link_libraries/RunCMakeTest.cmake @@ -10,3 +10,4 @@ run_cmake(SubDirTarget) run_cmake(SharedDepNotTarget) run_cmake(StaticPrivateDepNotExported) run_cmake(StaticPrivateDepNotTarget) +run_cmake(UNKNOWN-IMPORTED-GLOBAL) diff --git a/Tests/RunCMake/target_link_libraries/UNKNOWN-IMPORTED-GLOBAL.cmake b/Tests/RunCMake/target_link_libraries/UNKNOWN-IMPORTED-GLOBAL.cmake new file mode 100644 index 0000000..f52fa30 --- /dev/null +++ b/Tests/RunCMake/target_link_libraries/UNKNOWN-IMPORTED-GLOBAL.cmake @@ -0,0 +1,4 @@ +enable_language(C) +add_library(UnknownImportedGlobal UNKNOWN IMPORTED GLOBAL) +add_library(mylib empty.c) +target_link_libraries(mylib UnknownImportedGlobal) |