diff options
author | Marc Chevrier <marc.chevrier@gmail.com> | 2022-10-13 15:20:38 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-10-14 13:13:37 (GMT) |
commit | 4aa86da82798ed5d741e0204ce3c9f59aa697956 (patch) | |
tree | ce5811eed4f1dbff91fc9af2b07daad31e80b701 /Tests/RunCMake | |
parent | 20bfbf783894681f8aeb9bf6b0cff9f4c9443832 (diff) | |
download | CMake-4aa86da82798ed5d741e0204ce3c9f59aa697956.zip CMake-4aa86da82798ed5d741e0204ce3c9f59aa697956.tar.gz CMake-4aa86da82798ed5d741e0204ce3c9f59aa697956.tar.bz2 |
Xcode: ensure framework with custom output directory can be consumed
Fixes: #24046
Diffstat (limited to 'Tests/RunCMake')
-rw-r--r-- | Tests/RunCMake/Framework/FrameworkConsumption.cmake | 18 | ||||
-rw-r--r-- | Tests/RunCMake/Framework/main2.c | 9 |
2 files changed, 27 insertions, 0 deletions
diff --git a/Tests/RunCMake/Framework/FrameworkConsumption.cmake b/Tests/RunCMake/Framework/FrameworkConsumption.cmake index 4663166..58b70a3 100644 --- a/Tests/RunCMake/Framework/FrameworkConsumption.cmake +++ b/Tests/RunCMake/Framework/FrameworkConsumption.cmake @@ -13,3 +13,21 @@ set_target_properties(Gui PROPERTIES add_executable(app main.c) target_link_libraries(app PRIVATE Gui) + + +# Same test but with generation done in custom directories +add_library(Gui2 SHARED Gui.c "${input_header}") +set_target_properties(Gui2 PROPERTIES + PUBLIC_HEADER "${input_header}" + FRAMEWORK TRUE + LIBRARY_OUTPUT_DIRECTORY lib +) + +add_executable(app2 main2.c) +set_target_properties(Gui2 PROPERTIES + PUBLIC_HEADER "${input_header}" + FRAMEWORK TRUE + RUNTIME_OUTPUT_DIRECTORY bin +) + +target_link_libraries(app2 PRIVATE Gui2) diff --git a/Tests/RunCMake/Framework/main2.c b/Tests/RunCMake/Framework/main2.c new file mode 100644 index 0000000..11f4e4d --- /dev/null +++ b/Tests/RunCMake/Framework/main2.c @@ -0,0 +1,9 @@ + +#include <Gui2/Gui.h> + +int main() +{ + foo(); + + return 0; +} |