Skip to content

Commit

Permalink
Add option to select building Georeferencer plugin
Browse files Browse the repository at this point in the history
If selected require GSL to be installed
  • Loading branch information
cjmayo authored and m-kuhn committed Mar 4, 2017
1 parent 191c11a commit d50930c
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ matrix:
- libpq-dev
- libfcgi-dev
- libfftw3-3
- libgsl0-dev
- pkg-config
- poppler-utils
- txt2tags
Expand Down
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ ELSE (ANDROID)
ENDIF (ANDROID)
SET (WITH_QTMOBILITY ${DEFAULT_WITH_QTMOBILITY} CACHE BOOL "Determines if QtMobility related code should be build (for example internal GPS)")

SET (WITH_GEOREFERENCER TRUE CACHE BOOL "Determines whether GeoReferencer plugin should be built")

SET (WITH_GLOBE FALSE CACHE BOOL "Determines whether Globe plugin should be built")
IF (WITH_GLOBE)
SET(QT_USE_QTOPENGL 1)
Expand Down
2 changes: 1 addition & 1 deletion cmake/FindGSL.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ ELSE(WIN32)
)

ELSE(GSL_CONFIG)
MESSAGE("FindGSL.cmake: gsl-config not found. Please set it manually. GSL_CONFIG=${GSL_CONFIG}")
MESSAGE(FATAL_ERROR "FindGSL.cmake: gsl-config not found. Please install the libgsl development libraries or set the path with -DGSL_CONFIG=/path/to/gsl-config.")
ENDIF(GSL_CONFIG)
ENDIF (NOT GSL_INCLUDE_DIR OR NOT GSL_LIBRARIES OR NOT GSL_CONFIG)
ENDIF(UNIX)
Expand Down
5 changes: 4 additions & 1 deletion src/plugins/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ SET (CMAKE_LIBRARY_OUTPUT_DIRECTORY ${QGIS_OUTPUT_DIRECTORY}/${QGIS_PLUGIN_SUBDI
ADD_SUBDIRECTORY(coordinate_capture)
ADD_SUBDIRECTORY(evis)
ADD_SUBDIRECTORY(spatialquery)
ADD_SUBDIRECTORY(georeferencer)
ADD_SUBDIRECTORY(gps_importer)
ADD_SUBDIRECTORY(topology)
ADD_SUBDIRECTORY(offline_editing)
Expand All @@ -19,6 +18,10 @@ IF (GRASS_FOUND)
ADD_SUBDIRECTORY(grass)
ENDIF (GRASS_FOUND)

IF (WITH_GEOREFERENCER)
ADD_SUBDIRECTORY(georeferencer)
ENDIF (WITH_GEOREFERENCER)

IF (WITH_GLOBE)
ADD_SUBDIRECTORY(globe)
ENDIF (WITH_GLOBE)
Expand Down
6 changes: 1 addition & 5 deletions src/plugins/georeferencer/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
FIND_PACKAGE(GSL) # Georeferencer

IF(GSL_FOUND)
FIND_PACKAGE(GSL REQUIRED) # Georeferencer

########################################################
# Files
Expand Down Expand Up @@ -106,5 +104,3 @@ TARGET_LINK_LIBRARIES(georefplugin
INSTALL(TARGETS georefplugin
RUNTIME DESTINATION ${QGIS_PLUGIN_DIR}
LIBRARY DESTINATION ${QGIS_PLUGIN_DIR})

ENDIF(GSL_FOUND)

0 comments on commit d50930c

Please sign in to comment.