summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CMakeScripts/HelperMacros.cmake10
-rw-r--r--src/CMakeLists.txt15
2 files changed, 8 insertions, 17 deletions
diff --git a/CMakeScripts/HelperMacros.cmake b/CMakeScripts/HelperMacros.cmake
index 54bbf9d09..0f7d755fd 100644
--- a/CMakeScripts/HelperMacros.cmake
+++ b/CMakeScripts/HelperMacros.cmake
@@ -34,16 +34,6 @@ macro(add_inkscape_lib
# works fine without having the includes
# listed is helpful for IDE's (QtCreator/MSVC)
inkscape_source_group("${sources}")
-
- # static libraries are probably not useful on Windows
- # (if we ever build shared libraries those would use the RUNTIME target and we might have to revisit this)
- if(NOT WIN32)
- install(TARGETS ${name}
- LIBRARY DESTINATION lib/inkscape
- ARCHIVE DESTINATION lib/inkscape
- )
- endif()
-
endmacro()
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index de5419de8..342691151 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -559,19 +559,20 @@ target_link_libraries(inkview inkscape_base)
#Define the installation
if(NOT WIN32)
install(TARGETS
- inkscape_base
inkscape
inkview
- RUNTIME DESTINATION bin
- LIBRARY DESTINATION lib/inkscape
- ARCHIVE DESTINATION lib/inkscape)
+ RUNTIME DESTINATION bin)
+ if(BUILD_SHARED_LIBS)
+ install(TARGETS inkscape_base LIBRARY DESTINATION lib/inkscape)
+ endif()
else()
install(TARGETS
- inkscape_base
inkscape
inkscape_com
inkview
inkview_com
- RUNTIME DESTINATION .
- ARCHIVE DESTINATION .)
+ RUNTIME DESTINATION .)
+ if(BUILD_SHARED_LIBS)
+ install(TARGETS inkscape_base RUNTIME DESTINATION .)
+ endif()
endif()