diff --git a/CMakeLists.txt b/CMakeLists.txt index 1dbc5a35c03..c56e29b2c89 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,7 +5,7 @@ SET(COMPLETE_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINO SET(RELEASE_NAME "Metis") SET(PROJECT_VERSION ${COMPLETE_VERSION}) PROJECT(qgis${PROJECT_VERSION}) - +SET(QGIS_VERSION_INT 1100) # TODO: # - install includes for libs @@ -26,6 +26,12 @@ SET(CMAKE_COLOR_MAKEFILE ON) # set path to additional CMake modules SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH}) +# in generated makefiles use relative paths so the project dir is moveable +# Note commented out since it cause problems but it would be nice to resolve these and enable +# +# issue is caused by INCLUDE_DIRECTORIES(${CMAKE_BINARY_DIR}) near the end of this file generating incorrect path +#SET (CMAKE_USE_RELATIVE_PATHS ON) + # it's possible to set PLUGINS_ALSO_BINARIES to TRUE # then some plugins that can run as standalone apps will be built # also as standalone apps diff --git a/cmake_templates/qgsconfig.h.in b/cmake_templates/qgsconfig.h.in index 0a302aa89cc..6853c315c93 100644 --- a/cmake_templates/qgsconfig.h.in +++ b/cmake_templates/qgsconfig.h.in @@ -11,7 +11,12 @@ #define VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}-${RELEASE_NAME}" //used in vim src/core/qgis.cpp -#define VERSION_INT ${CPACK_PACKAGE_VERSION_MAJOR}${CPACK_PACKAGE_VERSION_MINOR}${CPACK_PACKAGE_VERSION_PATCH} +//The way below should work but it resolves to a number like 0110 which the compiler treats as octal I think +//because debuggin it out shows the decimal number 72 which results in incorrect version status. +//As a short term fix I (Tim) am defining the version in top level cmake. It would be good to +//reinstate this more generic approach below at some point though +//#define VERSION_INT ${CPACK_PACKAGE_VERSION_MAJOR}${CPACK_PACKAGE_VERSION_MINOR}${CPACK_PACKAGE_VERSION_PATCH} +#define VERSION_INT ${QGIS_VERSION_INT} //used in main.cpp and anywhere else where the release name is needed #define RELEASE_NAME "${RELEASE_NAME}" diff --git a/src/app/qgisapp.cpp b/src/app/qgisapp.cpp index 909b30306a7..e5bf7b32414 100644 --- a/src/app/qgisapp.cpp +++ b/src/app/qgisapp.cpp @@ -4276,7 +4276,9 @@ void QgisApp::socketConnectionClosed() { versionInfo += parts[1] + "\n\n" + tr("Would you like more information?"); ; - QMessageBox::StandardButton result = QMessageBox::information(this, tr("QGIS Version Information"), versionInfo, QMessageBox::Ok | QMessageBox::Cancel); + QMessageBox::StandardButton result = QMessageBox::information(this, + tr("QGIS Version Information"), versionInfo, QMessageBox::Ok | + QMessageBox::Cancel); if (result == QMessageBox::Ok) { // show more info