Skip to content
Permalink
Browse files

Library install directory made configurable (using QGIS_LIB_DIR)

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@7456 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder
wonder committed Nov 18, 2007
1 parent a469913 commit aaa9ddf34017bd704724793a64b49bb0d3aa2c38
Showing with 11 additions and 7 deletions.
  1. +5 −1 CMakeLists.txt
  2. +1 −1 src/app/CMakeLists.txt
  3. +2 −2 src/core/CMakeLists.txt
  4. +2 −2 src/gui/CMakeLists.txt
  5. +1 −1 src/providers/grass/CMakeLists.txt
@@ -140,6 +140,7 @@ ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)

IF (WIN32)
SET (DEFAULT_BIN_SUBDIR .)
SET (DEFAULT_LIB_SUBDIR .)
SET (DEFAULT_DATA_SUBDIR .)
SET (DEFAULT_PLUGIN_SUBDIR plugins)
SET (DEFAULT_INCLUDE_SUBDIR include)
@@ -175,6 +176,7 @@ ELSE (WIN32)

# common for MAC and UNIX
SET (DEFAULT_BIN_SUBDIR bin)
SET (DEFAULT_LIB_SUBDIR lib)
SET (DEFAULT_DATA_SUBDIR share/qgis)
SET (DEFAULT_PLUGIN_SUBDIR lib/qgis)
SET (DEFAULT_INCLUDE_SUBDIR include/qgis)
@@ -209,16 +211,18 @@ ENDIF (WIN32)
# (default values are platform-specific)

SET (QGIS_BIN_SUBDIR ${DEFAULT_BIN_SUBDIR} CACHE STRING "Subdirectory where executables will be installed")
SET (QGIS_LIB_SUBDIR ${DEFAULT_LIB_SUBDIR} CACHE STRING "Subdirectory where libraries will be installed")
SET (QGIS_DATA_SUBDIR ${DEFAULT_DATA_SUBDIR} CACHE STRING "Subdirectory where QGIS data will be installed")
SET (QGIS_PLUGIN_SUBDIR ${DEFAULT_PLUGIN_SUBDIR} CACHE STRING "Subdirectory where plugins will be installed")
SET (QGIS_INCLUDE_SUBDIR ${DEFAULT_INCLUDE_SUBDIR} CACHE STRING "Subdirectory where header files will be installed")

# mark *_SUBDIR variables as advanced as this is not something
# that an average user would use
MARK_AS_ADVANCED (QGIS_BIN_SUBDIR QGIS_DATA_SUBDIR QGIS_PLUGIN_SUBDIR QGIS_INCLUDE_SUBDIR)
MARK_AS_ADVANCED (QGIS_BIN_SUBDIR QGIS_LIB_SUBDIR QGIS_DATA_SUBDIR QGIS_PLUGIN_SUBDIR QGIS_INCLUDE_SUBDIR)

# full paths for the installation
SET (QGIS_BIN_DIR ${CMAKE_INSTALL_PREFIX}/${QGIS_BIN_SUBDIR})
SET (QGIS_LIB_DIR ${CMAKE_INSTALL_PREFIX}/${QGIS_LIB_SUBDIR})
SET (QGIS_DATA_DIR ${CMAKE_INSTALL_PREFIX}/${QGIS_DATA_SUBDIR})
SET (QGIS_PLUGIN_DIR ${CMAKE_INSTALL_PREFIX}/${QGIS_PLUGIN_SUBDIR})
SET (QGIS_INCLUDE_DIR ${CMAKE_INSTALL_PREFIX}/${QGIS_INCLUDE_SUBDIR})
@@ -225,7 +225,7 @@ IF (MSVC)
ENDIF (MSVC)

SET_TARGET_PROPERTIES(qgis PROPERTIES
INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib
INSTALL_RPATH ${QGIS_LIB_DIR}
INSTALL_RPATH_USE_LINK_PATH true
)

@@ -171,8 +171,8 @@ ENDIF (APPLE)

INSTALL(TARGETS qgis_core
RUNTIME DESTINATION ${QGIS_BIN_DIR}
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib)
LIBRARY DESTINATION ${QGIS_LIB_DIR}
ARCHIVE DESTINATION ${QGIS_LIB_DIR})


# Added by Tim to install headers
@@ -79,8 +79,8 @@ ENDIF (APPLE)

INSTALL(TARGETS qgis_gui
RUNTIME DESTINATION ${QGIS_BIN_DIR}
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib)
LIBRARY DESTINATION ${QGIS_LIB_DIR}
ARCHIVE DESTINATION ${QGIS_LIB_DIR})

# for installing headers

@@ -65,7 +65,7 @@ TARGET_LINK_LIBRARIES (grassprovider

INSTALL(TARGETS qgisgrass
RUNTIME DESTINATION ${QGIS_BIN_DIR}
LIBRARY DESTINATION lib)
LIBRARY DESTINATION ${QGIS_LIB_DIR})

INSTALL(TARGETS grassprovider
RUNTIME DESTINATION ${QGIS_PLUGIN_DIR}

0 comments on commit aaa9ddf

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