Skip to content
Permalink
Browse files

fix windows build

  • Loading branch information
jef-n committed Jul 5, 2011
1 parent 97f8039 commit 6d90708e86b42c7925198f41cc846ac5a8cecd7f
Showing with 56 additions and 56 deletions.
  1. +31 −31 cmake/FindQGIS.cmake
  2. +9 −13 images/icons/CMakeLists.txt
  3. +1 −1 python/pyspatialite/CMakeLists.txt
  4. +4 −0 src/app/CMakeLists.txt
  5. +11 −11 src/core/CMakeLists.txt
@@ -1,12 +1,12 @@
## Once run this will define:
##
## Once run this will define:
##
## QGIS_FOUND = system has QGIS lib
##
## QGIS_CORE_LIBRARY = full path to the CORE library
## QGIS_GUI_LIBRARY = full path to the GUI library
## QGIS_ANALYSIS_LIBRARY = full path to the ANALYSIS library
## QGIS_PLUGIN_DIR = full path to where QGIS plugins are installed
## QGIS_INCLUDE_DIR = where to find headers
## QGIS_INCLUDE_DIR = where to find headers
##
## Tim Sutton

@@ -20,9 +20,9 @@ IF(WIN32)
"$ENV{PROGRAMFILES}/Quantum GIS/plugins"
)
FIND_PATH(QGIS_INCLUDE_DIR
NAMES qgsapplication.h
NAMES qgsapplication.h
PATHS
"$ENV{PROGRAMFILES}/Quantum GIS/include"
"$ENV{PROGRAMFILES}/Quantum GIS/include"
)
FIND_LIBRARY(QGIS_CORE_LIBRARY
NAMES qgis_core
@@ -43,41 +43,41 @@ IF(WIN32)
"$ENV{OSGEO4W_ROOT}/apps/qgis/plugins"
"$ENV{PROGRAMFILES}/Quantum GIS/plugins"
)
FIND_PATH(QGIS_INCLUDE_DIR
NAMES qgsapplication.h
FIND_PATH(QGIS_INCLUDE_DIR
NAMES qgsapplication.h
PATHS
"$ENV{INCLUDE}"
"$ENV{LIB_DIR}/include/qgis"
"$ENV{INCLUDE}"
"$ENV{LIB_DIR}/include/qgis"
"$ENV{OSGEO4W_ROOT}/include"
"$ENV{PROGRAMFILES}/Quantum GIS/include"
)
FIND_LIBRARY(QGIS_CORE_LIBRARY
NAMES qgis_core
PATHS
"$ENV{LIB_DIR}/lib/"
"$ENV{LIB}"
PATHS
"$ENV{LIB_DIR}/lib/"
"$ENV{LIB}"
"$ENV{OSGEO4W_ROOT}/lib"
"$ENV{PROGRAMFILES}/Quantum GIS/lib"
)
FIND_LIBRARY(QGIS_GUI_LIBRARY
NAMES qgis_gui
PATHS
"$ENV{LIB_DIR}"
"$ENV{LIB}"
PATHS
"$ENV{LIB_DIR}"
"$ENV{LIB}"
"$ENV{OSGEO4W_ROOT}/lib"
"$ENV{PROGRAMFILES}/Quantum GIS/lib"
)
FIND_LIBRARY(QGIS_ANALYSIS_LIBRARY
NAMES qgis_analysis
PATHS
"$ENV{LIB_DIR}"
"$ENV{LIB}"
PATHS
"$ENV{LIB_DIR}"
"$ENV{LIB}"
"$ENV{OSGEO4W_ROOT}/lib"
"$ENV{PROGRAMFILES}/Quantum GIS/lib"
)
ENDIF (MSVC)
ELSE(WIN32)
IF(UNIX)
IF(UNIX)
# try to use bundle on mac
SET (QGIS_MAC_PATH /Applications/QGIS.app/Contents)
#MESSAGE("Searching for QGIS in /usr/bin; /usr/local/bin")
@@ -88,25 +88,25 @@ ELSE(WIN32)
/usr/lib/qgis
/usr/local/lib/qgis/plugins
${QGIS_MAC_PATH}/PlugIns/qgis
"$ENV{LIB_DIR}/lib/qgis/plugins"
"$ENV{LIB_DIR}/lib/qgis"
"$ENV{LIB_DIR}/lib/qgis/plugins"
"$ENV{LIB_DIR}/lib/qgis"
)
FIND_PATH(QGIS_INCLUDE_DIR
NAMES qgis.h
NAMES qgis.h
PATHS
/usr/include/qgis
/usr/local/include/qgis
${QGIS_MAC_PATH}/Frameworks/qgis_core.framework/Headers
"$ENV{LIB_DIR}/include/qgis"
"$ENV{LIB_DIR}/include/qgis"
)
# also get other frameworks' headers folders on OS X
IF (APPLE)
FIND_PATH(QGIS_GUI_INCLUDE_DIR
NAMES qgisgui.h
NAMES qgisgui.h
PATHS ${QGIS_MAC_PATH}/Frameworks/qgis_gui.framework/Headers
)
FIND_PATH(QGIS_ANALYSIS_INCLUDE_DIR
NAMES qgsinterpolator.h
NAMES qgsinterpolator.h
PATHS ${QGIS_MAC_PATH}/Frameworks/qgis_analysis.framework/Headers
)
SET(QGIS_INCLUDE_DIR
@@ -117,30 +117,30 @@ ELSE(WIN32)
ENDIF (APPLE)
FIND_LIBRARY(QGIS_CORE_LIBRARY
NAMES qgis_core
PATHS
PATHS
/usr/lib64
/usr/lib
/usr/local/lib
${QGIS_MAC_PATH}/Frameworks
"$ENV{LIB_DIR}/lib/"
"$ENV{LIB_DIR}/lib/"
)
FIND_LIBRARY(QGIS_GUI_LIBRARY
NAMES qgis_gui
PATHS
PATHS
/usr/lib64
/usr/lib
/usr/local/lib
${QGIS_MAC_PATH}/Frameworks
"$ENV{LIB_DIR}/lib/"
"$ENV{LIB_DIR}/lib/"
)
FIND_LIBRARY(QGIS_ANALYSIS_LIBRARY
NAMES qgis_analysis
PATHS
PATHS
/usr/lib64
/usr/lib
/usr/local/lib
${QGIS_MAC_PATH}/Frameworks
"$ENV{LIB_DIR}/lib/"
"$ENV{LIB_DIR}/lib/"
)
ENDIF(UNIX)
ENDIF(WIN32)
@@ -1,13 +1,9 @@

FILE (GLOB IMAGES *.png)
INSTALL (FILES ${IMAGES}
DESTINATION ${QGIS_DATA_DIR}/images/icons)

IF(MSVC)
INSTALL(FILES qgis.ico DESTINATION ${CMAKE_INSTALL_PREFIX}/icons)
ENDIF(MSVC)

# OS X app/doc icons
IF (APPLE)
ADD_SUBDIRECTORY(mac)
ENDIF (APPLE)

FILE (GLOB IMAGES *.png)
INSTALL (FILES ${IMAGES}
DESTINATION ${QGIS_DATA_DIR}/images/icons)

# OS X app/doc icons
IF (APPLE)
ADD_SUBDIRECTORY(mac)
ENDIF (APPLE)
@@ -31,7 +31,7 @@ IF (NOT APPLE)
TARGET_LINK_LIBRARIES(pyspatialite ${PYTHON_LIBRARY})
ENDIF (NOT APPLE)

TARGET_LINK_LIBRARIES(pyspatialite ${EXTRA_LINK_LIBRARIES})
TARGET_LINK_LIBRARIES(pyspatialite qgis_core)

IF (APPLE)
SET_TARGET_PROPERTIES(pyspatialite PROPERTIES LINK_FLAGS "-undefined dynamic_lookup")
@@ -423,6 +423,10 @@ INSTALL(TARGETS ${QGIS_APP_NAME}
BUNDLE DESTINATION ${QGIS_INSTALL_PREFIX}
RUNTIME DESTINATION ${QGIS_BIN_DIR})

IF (MSVC)
INSTALL(FILES qgis.ico DESTINATION ${CMAKE_INSTALL_PREFIX}/icons)
ENDIF (MSVC)

IF (APPLE)
INSTALL(CODE "EXECUTE_PROCESS(COMMAND /bin/echo -n \"APPLQGIS\" OUTPUT_FILE \"$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/../PkgInfo\")")
ENDIF (APPLE)
@@ -164,7 +164,7 @@ SET(QGIS_CORE_SRCS
symbology/qgssymbologyutils.cpp

spatialindex/qgsspatialindex.cpp

)

IF(WIN32)
@@ -346,7 +346,7 @@ SET(QGIS_CORE_HDRS
raster/qgsrastershader.h
raster/qgsrastershaderfunction.h
raster/qgsrasterviewport.h

renderer/qgscontinuouscolorrenderer.h
renderer/qgsgraduatedsymbolrenderer.h
renderer/qgsrenderer.h
@@ -379,11 +379,11 @@ SET(QGIS_CORE_HDRS
)

INCLUDE_DIRECTORIES(
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
composer
pal
raster
renderer
raster
renderer
symbology
spatialindex/include
symbology-ng
@@ -465,12 +465,12 @@ IF(APPLE)
ENDIF(APPLE)

TARGET_LINK_LIBRARIES(qgis_core
${QT_QTMAIN_LIBRARY}
${QT_QTXML_LIBRARY}
${QT_QTCORE_LIBRARY}
${QT_QTGUI_LIBRARY}
${QT_QTNETWORK_LIBRARY}
${QT_QTSVG_LIBRARY}
${QT_QTMAIN_LIBRARY}
${QT_QTXML_LIBRARY}
${QT_QTCORE_LIBRARY}
${QT_QTGUI_LIBRARY}
${QT_QTNETWORK_LIBRARY}
${QT_QTSVG_LIBRARY}

${PROJ_LIBRARY}
${GEOS_LIBRARY}

0 comments on commit 6d90708

Please sign in to comment.
You can’t perform that action at this time.