Skip to content
Permalink
Browse files
detect iconv on macosx
git-svn-id: http://svn.osgeo.org/qgis/trunk@10488 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Apr 6, 2009
1 parent 472848e commit 1bfc5c6adb0d13783b88b629c6302d14e1a16be4
Showing with 11 additions and 5 deletions.
  1. +2 −2 CMakeLists.txt
  2. +4 −0 cmake/FindIconv.cmake
  3. +5 −3 src/core/CMakeLists.txt
@@ -57,9 +57,9 @@ IF (WITH_SPATIALITE)
IF(WITH_INTERNAL_SPATIALITE)
SET(SPATIALITE_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/src/core/spatialite/headers)
SET(HAVE_SPATIALITE TRUE)
IF(WIN32)
IF(WIN32 OR APPLE)
FIND_PACKAGE(Iconv REQUIRED)
ENDIF(WIN32)
ENDIF(WIN32 OR APPLE)
ENDIF (WITH_INTERNAL_SPATIALITE)
ENDIF (WITH_SPATIALITE)

@@ -13,6 +13,8 @@
# searching for the same item do nothing.
FIND_PATH(ICONV_INCLUDE_DIR iconv.h
"$ENV{LIB_DIR}/include"
/usr/local/include
/usr/include
#mingw
c:/msys/local/include
NO_DEFAULT_PATH
@@ -21,6 +23,8 @@ FIND_PATH(ICONV_INCLUDE_DIR iconv.h)

FIND_LIBRARY(ICONV_LIBRARY NAMES iconv PATHS
"$ENV{LIB_DIR}/lib"
/usr/local/lib
/usr/lib
#mingw
c:/msys/local/lib
NO_DEFAULT_PATH
@@ -110,8 +110,10 @@ SET(QGIS_CORE_SRCS
)

IF (WITH_INTERNAL_SPATIALITE)
IF (WIN32)
IF (WIN32 OR APPLE)
INCLUDE_DIRECTORIES(${ICONV_INCLUDE_DIR})
ENDIF (WIN32 OR APPLE)
IF (WIN32)
ADD_DEFINITIONS(-DDLL_EXPORT)
IF (MSVC)
ADD_DEFINITIONS("-DSQLITE_API=__declspec(dllexport)")
@@ -294,9 +296,9 @@ TARGET_LINK_LIBRARIES(qgis_core
)

IF (WITH_INTERNAL_SPATIALITE)
IF (WIN32)
IF (WIN32 OR APPLE)
TARGET_LINK_LIBRARIES(qgis_core ${ICONV_LIBRARY})
ENDIF (WIN32)
ENDIF (WIN32 OR APPLE)
ELSE (WITH_INTERNAL_SPATIALITE)
TARGET_LINK_LIBRARIES(qgis_core ${SQLITE3_LIBRARY})
ENDIF (WITH_INTERNAL_SPATIALITE)

0 comments on commit 1bfc5c6

Please sign in to comment.