Commit b177c67b authored by Emmanuel Christophe's avatar Emmanuel Christophe

BUG: find libintl for windows and mac platforms

parent 3fd972bc
......@@ -617,12 +617,16 @@ IF(GETTEXT_FOUND)
FIND_PATH(GETTEXT_INCLUDE_DIR
libintl.h
DOC "Path to gettext include directory (where libintl.h can be found)")
FIND_LIBRARY(GETTEXT_LIBRARY gettextlib
DOC "GetText library")
MARK_AS_ADVANCED(GETTEXT_INCLUDE_DIR)
IF(GETTEXT_INCLUDE_DIR)
INCLUDE_DIRECTORIES(${GETTEXT_INCLUDE_DIR})
ENDIF(GETTEXT_INCLUDE_DIR)
FIND_LIBRARY(GETTEXT_LIBRARY gettextlib DOC "GetText library")
IF(APPLE OR WIN32)
FIND_LIBRARY(GETTEXT_INTL_LIBRARY intl DOC "GetText intl library")
ENDIF(APPLE OR WIN32)
ELSE(GETTEXT_FOUND)
SET(OTB_I18N 0)
MESSAGE(STATUS
......
......@@ -24,6 +24,9 @@ ENDIF(OTB_USE_PQXX)
IF(GETTEXT_FOUND)
TARGET_LINK_LIBRARIES(OTBCommon ${GETTEXT_LIBRARY})
IF(APPLE OR WIN32)
TARGET_LINK_LIBRARIES(OTBCommon ${GETTEXT_INTL_LIBRARY})
ENDIF(APPLE OR WIN32)
ENDIF(GETTEXT_FOUND)
IF(OTB_LIBRARY_PROPERTIES)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment