diff options
author | Pino Toscano <pino@kde.org> | 2012-02-20 22:18:00 +0100 |
---|---|---|
committer | Pino Toscano <pino@kde.org> | 2012-02-20 22:18:00 +0100 |
commit | d0186c558f4a84a9317687ad50b460d34fb5fdf0 (patch) | |
tree | f2406af118ce3482d54cd211e9c04cebd6ff447f /CMakeLists.txt | |
parent | e48c22d3b70412015b9cc07a9a6ce07845274e13 (diff) |
cmake: support for lcms2
followup of e48c22d3b70412015b9cc07a9a6ce07845274e13 also for the CMake build system,
importing the FindLCMS2.cmake from kdelibs
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 9f438cce..38300661 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -137,8 +137,14 @@ if(ENABLE_LIBOPENJPEG) set(HAVE_OPENJPEG_H ON) endif(ENABLE_LIBOPENJPEG) if(ENABLE_LCMS) - find_package(LCMS) - set(USE_CMS ${LCMS_FOUND}) + find_package(LCMS2) + if(LCMS2_FOUND) + set(USE_CMS ${LCMS2_FOUND}) + else(LCMS2_FOUND) + find_package(LCMS) + set(USE_CMS ${LCMS_FOUND}) + set(USE_LCMS1 ${LCMS_FOUND}) + endif(LCMS2_FOUND) endif(ENABLE_LCMS) if(ENABLE_LIBCURL) find_package(CURL) @@ -192,6 +198,9 @@ endif(LIBOPENJPEG_FOUND) if(LCMS_FOUND) include_directories(${LCMS_INCLUDE_DIR}) endif(LCMS_FOUND) +if(LCMS2_FOUND) + include_directories(${LCMS2_INCLUDE_DIR}) +endif(LCMS2_FOUND) if(DEFINED COMPILE_WARNINGS) else(DEFINED COMPILE_WARNINGS) @@ -352,7 +361,12 @@ else (LIBOPENJPEG_FOUND) ) endif(LIBOPENJPEG_FOUND) if(USE_CMS) - set(poppler_LIBS ${poppler_LIBS} ${LCMS_LIBRARIES}) + if(LCMS_FOUND) + set(poppler_LIBS ${poppler_LIBS} ${LCMS_LIBRARIES}) + endif(LCMS_FOUND) + if(LCMS2_FOUND) + set(poppler_LIBS ${poppler_LIBS} ${LCMS2_LIBRARIES}) + endif(LCMS2_FOUND) endif(USE_CMS) if(WIN32) # gdi32 is needed under win32 @@ -595,6 +609,12 @@ show_end_message_yesno("use zlib" ENABLE_ZLIB) show_end_message_yesno("use curl" ENABLE_LIBCURL) show_end_message_yesno("use libopenjpeg" LIBOPENJPEG_FOUND) show_end_message_yesno("use cms" USE_CMS) +if(LCMS_FOUND) + message(" with lcms1") +endif(LCMS_FOUND) +if(LCMS2_FOUND) + message(" with lcms2") +endif(LCMS2_FOUND) show_end_message_yesno("command line utils" ENABLE_UTILS) show_end_message("test data dir" ${TESTDATADIR}) |