Skip to content

Commit

Permalink
Make QScintilla a required dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jul 7, 2014
1 parent f4a51c4 commit e13e9f7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 17 deletions.
14 changes: 1 addition & 13 deletions CMakeLists.txt
Expand Up @@ -256,14 +256,7 @@ ELSE (WITH_TOUCH)
ENDIF (WITH_TOUCH)

# search for QScintilla2 (C++ lib)
IF (WITH_BINDINGS)
# TODO: make required after testing find paths on Windows platforms
#FIND_PACKAGE(QScintilla REQUIRED)
FIND_PACKAGE(QScintilla)
ELSE (WITH_BINDINGS)
# for when library is used in .h/cpp
FIND_PACKAGE(QScintilla)
ENDIF (WITH_BINDINGS)
FIND_PACKAGE(QScintilla REQUIRED)

IF (ENABLE_TESTS)
SET( QT_USE_QTTEST TRUE )
Expand Down Expand Up @@ -589,11 +582,6 @@ IF (WITH_BINDINGS)

ENDIF (WITH_BINDINGS)

# Set QSCINTILLA_VERSION_STR to that of module, if no headers found
IF (NOT EXISTS QSCINTILLA_VERSION_STR AND EXISTS QSCI_MOD_VERSION_STR)
SET(QSCINTILLA_VERSION_STR ${QSCI_MOD_VERSION_STR})
ENDIF (NOT EXISTS QSCINTILLA_VERSION_STR AND EXISTS QSCI_MOD_VERSION_STR)

#############################################################
# create qgsconfig.h
# installed with app target
Expand Down
6 changes: 2 additions & 4 deletions cmake/FindQScintilla.cmake
Expand Up @@ -41,9 +41,7 @@ ELSE(EXISTS QSCINTILLA_VERSION_STR)
/usr/lib
)

IF(QSCINTILLA_LIBRARY)
# QSCINTILLA_INCLUDE_DIR is not required at this time (Oct 2012) since only
# Qsci PyQt4 module is used, though lib is needed for Mac bundling
IF(QSCINTILLA_LIBRARY AND QSCINTILLA_INCLUDE_DIR)
SET(QSCINTILLA_FOUND TRUE)

IF(CYGWIN)
Expand All @@ -53,7 +51,7 @@ ELSE(EXISTS QSCINTILLA_VERSION_STR)
SET (QSCINTILLA_DEFINITIONS -DQSCINTILLA_STATIC)
ENDIF(BUILD_SHARED_LIBS)
ENDIF(CYGWIN)
ENDIF(QSCINTILLA_LIBRARY)
ENDIF(QSCINTILLA_LIBRARY AND QSCINTILLA_INCLUDE_DIR)

IF(QSCINTILLA_INCLUDE_DIR AND NOT EXISTS QSCINTILLA_VERSION_STR)
# get QScintilla2 version from header, is optinally retrieved via bindings
Expand Down
2 changes: 2 additions & 0 deletions src/gui/CMakeLists.txt
Expand Up @@ -596,6 +596,7 @@ ELSE (WITH_INTERNAL_SPATIALITE)
INCLUDE_DIRECTORIES(${SQLITE3_INCLUDE_DIR})
ENDIF (WITH_INTERNAL_SPATIALITE)

INCLUDE_DIRECTORIES(${QSCINTILLA_INCLUDE_DIR})
INCLUDE_DIRECTORIES(${GEOS_INCLUDE_DIR})
INCLUDE_DIRECTORIES(${GDAL_INCLUDE_DIR})

Expand Down Expand Up @@ -661,6 +662,7 @@ TARGET_LINK_LIBRARIES(qgis_gui
qgis_core
${QT_QTUITOOLS_LIBRARY}
${QWT_LIBRARY}
${QSCINTILLA_LIBRARY}
#${QT_QTTEST_LIBRARY} # for ModelTest
)

Expand Down

0 comments on commit e13e9f7

Please sign in to comment.