You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
exiv2/config/findDependencies.cmake

64 lines
1.9 KiB
CMake

# set include path for FindXXX.cmake files
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/config/")
find_package(Threads REQUIRED)
if( EXIV2_ENABLE_PNG )
find_package( ZLIB REQUIRED )
include_directories( ${ZLIB_INCLUDE_DIR} )
endif( EXIV2_ENABLE_PNG )
if( EXIV2_ENABLE_WEBREADY )
set( ENABLE_WEBREADY 1 )
if( EXIV2_ENABLE_CURL )
find_package( CURL REQUIRED)
include_directories( ${CURL_INCLUDE_DIR} )
endif()
if( EXIV2_ENABLE_SSH )
find_package( SSH REQUIRED)
include_directories( ${SSH_INCLUDE_DIR} )
endif( EXIV2_ENABLE_SSH )
endif( EXIV2_ENABLE_WEBREADY )
if (EXIV2_ENABLE_XMP)
find_package(EXPAT REQUIRED)
include_directories(${EXPAT_INCLUDE_DIR})
endif (EXIV2_ENABLE_XMP)
if( EXIV2_ENABLE_NLS )
find_package(Intl)
if(Intl_FOUND)
include_directories(${Intl_INCLUDE_DIRS})
set(LIBINTL_LIBRARIES ${Intl_LIBRARIES})
else()
set(LIBINTL_LIBRARIES)
endif()
if( NOT LOCALEDIR )
set( LOCALEDIR "${CMAKE_INSTALL_LOCALEDIR}" )
if( WIN32 )
STRING( REPLACE "/" "\\\\" LOCALEDIR ${LOCALEDIR} )
endif( WIN32 )
endif( NOT LOCALEDIR )
add_definitions( -DEXV_LOCALEDIR="${LOCALEDIR}" )
set( ENABLE_NLS 1 )
# TODO : This is assuming that Intl is always found. This check should be improved and remove
# the manual check in config/generateConfigFile.cmake
endif( EXIV2_ENABLE_NLS )
find_package(Iconv)
if( ICONV_FOUND )
include_directories(${ICONV_INCLUDE_DIR})
message ( "-- ICONV_INCLUDE_DIR : " ${ICONV_INCLUDE_DIR} )
message ( "-- ICONV_LIBRARIES : " ${ICONV_LIBRARIES} )
message ( "-- ICONV_ACCEPTS_CONST_INPUT : ${ICONV_ACCEPTS_CONST_INPUT}" )
endif( ICONV_FOUND )
if( EXIV2_ENABLE_BUILD_PO )
find_package(MSGFMT)
if(MSGFMT_FOUND)
message(STATUS "Program msgfmt found (${MSGFMT_EXECUTABLE})")
set( EXIV2_BUILD_PO 1 )
endif(MSGFMT_FOUND)
endif()