3 # =======================================================
4 # Informations to update before to release this library.
6 # Library version history:
8 # 0.1.0 => 0.1.0 (KDE3)
9 # 0.1.1 => 1.0.0 (KDE3)
10 # 0.1.2 => 2.0.0 (KDE3)
11 # 0.1.3 => 2.1.0 (KDE3)
12 # 0.1.4 => 3.0.0 (KDE3)
13 # 0.1.5 => 4.0.0 (KDE3)
14 # 0.2.0 => 5.0.0 (released with KDE 4.1.0)
15 # 0.3.0 => 6.0.0 (released with KDE 4.1.2)
16 # 0.4.0 => 7.0.0 (using libRaw-Released with KDE 4.2.0)
19 SET(DCRAW_LIB_MAJOR_VERSION "0")
20 SET(DCRAW_LIB_MINOR_VERSION "4")
21 SET(DCRAW_LIB_PATCH_VERSION "0")
23 # Suffix to add at end of version string. Usual values are:
24 # "-svn" : alpha code unstable from svn. Do not use in production
25 # "-beta1" : beta1 release.
26 # "-beta2" : beta2 release.
27 # "-beta3" : beta3 release.
28 # "-rc" : release candidate.
29 # "" : final relase. Can be used in production.
30 SET(DCRAW_LIB_SUFFIX_VERSION "")
32 # Library ABI version used by linker.
33 # For details : http://www.gnu.org/software/libtool/manual.html#Updating-version-info
34 SET(DCRAW_LIB_SO_CUR_VERSION "7")
35 SET(DCRAW_LIB_SO_REV_VERSION "0")
36 SET(DCRAW_LIB_SO_AGE_VERSION "0")
38 # =======================================================
39 # Set env. variables accordinly.
41 SET(DCRAW_LIB_VERSION_STRING "${DCRAW_LIB_MAJOR_VERSION}.${DCRAW_LIB_MINOR_VERSION}.${DCRAW_LIB_PATCH_VERSION}${DCRAW_LIB_SUFFIX_VERSION}")
42 SET(DCRAW_LIB_VERSION_ID "0x0${DCRAW_LIB_MAJOR_VERSION}0${DCRAW_LIB_MINOR_VERSION}0${DCRAW_LIB_PATCH_VERSION}")
44 SET(DCRAW_LIB_SO_VERSION_STRING "${DCRAW_LIB_SO_CUR_VERSION}.${DCRAW_LIB_SO_REV_VERSION}.${DCRAW_LIB_SO_AGE_VERSION}")
46 # =======================================================
50 FIND_LIBRARY(MATH_LIBRARY m)
53 # Flag to compile Little CMS code from LibRaw
54 ADD_DEFINITIONS(-DUSE_LCMS)
56 # Flag to debug LibRaw
57 ADD_DEFINITIONS(-DDCRAW_VERBOSE)
59 # LibRaw use C++ exception.
60 ADD_DEFINITIONS(${KDE4_ENABLE_EXCEPTIONS})
62 # Under Windows, use specific flag to compile.
64 ADD_DEFINITIONS( -DDJGPP )
70 ${CMAKE_CURRENT_SOURCE_DIR}/libraw
73 # Do not compile LibRaw with KDE FINAL mode.
74 KDE4_NO_ENABLE_FINAL(libraw)
76 SET(libraw_LIB_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/libraw/internal/dcraw_common.cpp
77 ${CMAKE_CURRENT_SOURCE_DIR}/libraw/internal/foveon.cpp
78 ${CMAKE_CURRENT_SOURCE_DIR}/libraw/src/libraw_cxx.cpp
79 ${CMAKE_CURRENT_SOURCE_DIR}/libraw/src/libraw_c_api.cpp
82 # =======================================================
85 CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libkdcraw.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/libkdcraw.pc)
86 CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libkdcraw.lsm.cmake ${CMAKE_CURRENT_BINARY_DIR}/libkdcraw.lsm)
87 INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/libkdcraw.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig)