Skip to content
Permalink
Browse files

[cmake] fix deprecated OLD policy for CMP0053

  • Loading branch information
3nids authored and nyalldawson committed Jun 7, 2018
1 parent d674a53 commit 088e94f9095cd7df0cba8c5b99d2f75ec233b699
Showing with 15 additions and 20 deletions.
  1. +13 −12 CMakeLists.txt
  2. +1 −4 cmake/FindGDAL.cmake
  3. +1 −4 cmake/FindGEOS.cmake
@@ -1,11 +1,20 @@
#############################################################
# CMake settings
CMAKE_MINIMUM_REQUIRED(VERSION 3.1.0)
SET(CMAKE_COLOR_MAKEFILE ON)
# set path to additional CMake modules
SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})
# POLICIES
CMAKE_POLICY (SET CMP0048 NEW)
CMAKE_POLICY (SET CMP0053 NEW)

#############################################################
# Project and version
SET(CPACK_PACKAGE_VERSION_MAJOR "3")
SET(CPACK_PACKAGE_VERSION_MINOR "1")
SET(CPACK_PACKAGE_VERSION_PATCH "0")
SET(COMPLETE_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH})
SET(RELEASE_NAME "Master")
IF (POLICY CMP0048)
CMAKE_POLICY (SET CMP0048 NEW)
ENDIF (POLICY CMP0048)
PROJECT(qgis VERSION ${COMPLETE_VERSION})
IF (APPLE)
SET(QGIS_APP_NAME "QGIS")
@@ -17,16 +26,8 @@ ENDIF (APPLE)
MATH(EXPR QGIS_VERSION_INT "${CPACK_PACKAGE_VERSION_MAJOR}*10000+${CPACK_PACKAGE_VERSION_MINOR}*100+${CPACK_PACKAGE_VERSION_PATCH}")
MESSAGE(STATUS "QGIS version: ${COMPLETE_VERSION} ${RELEASE_NAME} (${QGIS_VERSION_INT})")

#############################################################
# CMake settings

CMAKE_MINIMUM_REQUIRED(VERSION 3.0.0)

SET(CMAKE_COLOR_MAKEFILE ON)

# set path to additional CMake modules
SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})

#############################################################
# Configure CCache if available
option(USE_CCACHE "Use ccache" ON)
if (USE_CCACHE)
@@ -13,10 +13,7 @@
#
# GDAL_INCLUDE_DIR = where to find headers

IF (POLICY CMP0053) # in CMake 3.1.0+
CMAKE_POLICY (SET CMP0053 OLD) # keep old-style @VAR@ expansion
ENDIF (POLICY CMP0053)
INCLUDE (@CMAKE_SOURCE_DIR@/cmake/MacPlistMacros.cmake)
INCLUDE (${CMAKE_SOURCE_DIR}/cmake/MacPlistMacros.cmake)

IF(WIN32)

@@ -13,10 +13,7 @@
# GEOS_LIBRARY
#

IF (POLICY CMP0053) # in CMake 3.1.0+
CMAKE_POLICY (SET CMP0053 OLD) # keep old-style @VAR@ expansion
ENDIF (POLICY CMP0053)
INCLUDE (@CMAKE_SOURCE_DIR@/cmake/MacPlistMacros.cmake)
INCLUDE (${CMAKE_SOURCE_DIR}/cmake/MacPlistMacros.cmake)

IF(WIN32)

0 comments on commit 088e94f

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