From 351ecf9049d1a58bd3b625c5a6f75b0f78f68845 Mon Sep 17 00:00:00 2001 From: Wyatt Olson Date: Sat, 24 Apr 2010 14:09:19 -0600 Subject: [PATCH] Added patch for issue #79; cmake linking when build shared libraries enabled - patch from guillaume85 --- rtengine/CMakeLists.txt | 10 +++------- rtexif/CMakeLists.txt | 4 +++- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/rtengine/CMakeLists.txt b/rtengine/CMakeLists.txt index 79dd20984..fb46d13dd 100755 --- a/rtengine/CMakeLists.txt +++ b/rtengine/CMakeLists.txt @@ -12,13 +12,9 @@ set (RTENGINESOURCEFILES colortemp.cc curves.cc dcraw.cc gauss.cc iccstore.cc stdimagesource.cc myfile.cc iccjpeg.c hlmultipliers.cc improccoordinator.cc processingjob.cc rtthumbnail.cc utils.cc bilateral2.cc) -if (BUILD_SHARED) - add_library (rtengine SHARED ${RTENGINESOURCEFILES}) - # it may be nice to store library version too - install (TARGETS rtengine DESTINATION ${LIBDIR}) -else (BUILD_SHARED) - add_library (rtengine STATIC ${RTENGINESOURCEFILES}) -endif (BUILD_SHARED) +add_library (rtengine ${RTENGINESOURCEFILES}) +#It may be nice to store library version too +install (TARGETS rtengine DESTINATION ${LIBDIR}) 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 320a21a50..9acb54ec3 100755 --- a/rtexif/CMakeLists.txt +++ b/rtexif/CMakeLists.txt @@ -7,4 +7,6 @@ IF (WIN32) ELSE (WIN32) set_target_properties (rtexif PROPERTIES COMPILE_FLAGS "-O3 -ffast-math -fexpensive-optimizations -fPIC") ENDIF (WIN32) - \ No newline at end of file + +INSTALL(TARGETS rtexif DESTINATION ${LIBDIR}) +