diff options
author | Brad King <brad.king@kitware.com> | 2020-06-18 13:40:38 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2020-06-18 13:41:31 (GMT) |
commit | 3252bc447636b2345485704d646ce8739db12dfa (patch) | |
tree | 08eddf63540cd05ddab4f99d1b89684685ca158d /Help/guide/tutorial/Step11 | |
parent | d7541e80ed085811fc6180a124adfb5fe6fac519 (diff) | |
parent | 0fdfd6bf37146e1b09e410ff5f729f9ea8d3ac1a (diff) | |
download | CMake-3252bc447636b2345485704d646ce8739db12dfa.zip CMake-3252bc447636b2345485704d646ce8739db12dfa.tar.gz CMake-3252bc447636b2345485704d646ce8739db12dfa.tar.bz2 |
Merge topic 'tutorial_install_when_built_static'
0fdfd6bf37 Tutorial: Install correctly when built statically
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4906
Diffstat (limited to 'Help/guide/tutorial/Step11')
-rw-r--r-- | Help/guide/tutorial/Step11/MathFunctions/CMakeLists.txt | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Help/guide/tutorial/Step11/MathFunctions/CMakeLists.txt b/Help/guide/tutorial/Step11/MathFunctions/CMakeLists.txt index 32f5e08..0d287ca 100644 --- a/Help/guide/tutorial/Step11/MathFunctions/CMakeLists.txt +++ b/Help/guide/tutorial/Step11/MathFunctions/CMakeLists.txt @@ -51,5 +51,9 @@ target_link_libraries(MathFunctions PUBLIC tutorial_compiler_flags) target_compile_definitions(MathFunctions PRIVATE "EXPORTING_MYMATH") # install rules -install(TARGETS MathFunctions DESTINATION lib) +set(installable_libs MathFunctions tutorial_compiler_flags) +if(TARGET SqrtLibrary) + list(APPEND installable_libs SqrtLibrary) +endif() +install(TARGETS ${installable_libs} DESTINATION lib) install(FILES MathFunctions.h DESTINATION include) |