From f3aeb6ae1cd2fad1fdc8c06e07750171ef0812ca Mon Sep 17 00:00:00 2001 From: Michal Date: Tue, 27 Apr 2010 10:41:55 +0200 Subject: [PATCH] Avoid installation of static libraries. --- rtengine/CMakeLists.txt | 4 +++- rtexif/CMakeLists.txt | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/rtengine/CMakeLists.txt b/rtengine/CMakeLists.txt index fb46d13dd..f27265f7a 100644 --- a/rtengine/CMakeLists.txt +++ b/rtengine/CMakeLists.txt @@ -14,7 +14,9 @@ set (RTENGINESOURCEFILES colortemp.cc curves.cc dcraw.cc gauss.cc iccstore.cc add_library (rtengine ${RTENGINESOURCEFILES}) #It may be nice to store library version too -install (TARGETS rtengine DESTINATION ${LIBDIR}) +IF (BUILD_SHARED_LIBS) + install (TARGETS rtengine DESTINATION ${LIBDIR}) +ENDIF (BUILD_SHARED_LIBS) set_target_properties (rtengine PROPERTIES COMPILE_FLAGS "${CMAKE_CXX_FLAGS} -ffast-math -funroll-loops") diff --git a/rtexif/CMakeLists.txt b/rtexif/CMakeLists.txt index 9acb54ec3..17a6c18c8 100644 --- a/rtexif/CMakeLists.txt +++ b/rtexif/CMakeLists.txt @@ -8,5 +8,6 @@ ELSE (WIN32) set_target_properties (rtexif PROPERTIES COMPILE_FLAGS "-O3 -ffast-math -fexpensive-optimizations -fPIC") ENDIF (WIN32) -INSTALL(TARGETS rtexif DESTINATION ${LIBDIR}) - +IF (BUILD_SHARED_LIBS) + INSTALL(TARGETS rtexif DESTINATION ${LIBDIR}) +ENDIF (BUILD_SHARED_LIBS)