Merge pull request #1946 from jafj/EnableCMakePolicyCMP0077

Add support for CMake policy CMP0077
This commit is contained in:
Gabi Melman 2021-05-17 01:54:23 +03:00 committed by GitHub
commit af0d805be4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,6 +15,13 @@ message(STATUS "Build spdlog: ${SPDLOG_VERSION}")
include(GNUInstallDirs) include(GNUInstallDirs)
# ---------------------------------------------------------------------------------------
# Set CMake policies to support later version behaviour
# ---------------------------------------------------------------------------------------
if(POLICY CMP0077)
cmake_policy(SET CMP0077 NEW) # option() honors variables already set
endif()
# --------------------------------------------------------------------------------------- # ---------------------------------------------------------------------------------------
# Set default build to release # Set default build to release
# --------------------------------------------------------------------------------------- # ---------------------------------------------------------------------------------------