CMake: set policy for VERSION variables
Also update the description of other policies to the description on the CMake website.
This commit is contained in:
@@ -10,7 +10,7 @@
|
|||||||
# Please keep the policies in the order of their numbers.
|
# Please keep the policies in the order of their numbers.
|
||||||
|
|
||||||
if(POLICY CMP0025)
|
if(POLICY CMP0025)
|
||||||
# Compiler id for Apple Clang is now AppleClang
|
# Compiler id for Apple Clang is now AppleClang.
|
||||||
cmake_policy(SET CMP0025 NEW)
|
cmake_policy(SET CMP0025 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -20,7 +20,7 @@ if(POLICY CMP0028)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0038)
|
if(POLICY CMP0038)
|
||||||
# targets may not link directly to themselves
|
# Targets may not link directly to themselves.
|
||||||
cmake_policy(SET CMP0038 NEW)
|
cmake_policy(SET CMP0038 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -30,27 +30,32 @@ if(POLICY CMP0042)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0045)
|
if(POLICY CMP0045)
|
||||||
# error on non-existent target in get_target_property
|
# Error on non-existent target in get_target_property.
|
||||||
cmake_policy(SET CMP0045 NEW)
|
cmake_policy(SET CMP0045 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0046)
|
if(POLICY CMP0046)
|
||||||
# error on non-existent dependency in add_dependencies
|
# Error on non-existent dependency in add_dependencies.
|
||||||
cmake_policy(SET CMP0046 NEW)
|
cmake_policy(SET CMP0046 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(POLICY CMP0048)
|
||||||
|
# The project() command manages VERSION variables.
|
||||||
|
cmake_policy(SET CMP0048 NEW)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0049)
|
if(POLICY CMP0049)
|
||||||
# do not expand variables in target source entries
|
# Do not expand variables in target source entries.
|
||||||
cmake_policy(SET CMP0049 NEW)
|
cmake_policy(SET CMP0049 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0053)
|
if(POLICY CMP0053)
|
||||||
# simplify variable reference and escape sequence evaluation
|
# Simplify variable reference and escape sequence evaluation.
|
||||||
cmake_policy(SET CMP0053 NEW)
|
cmake_policy(SET CMP0053 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0054)
|
if(POLICY CMP0054)
|
||||||
# only interpret if() arguments as variables or keywords when unquoted
|
# Only interpret if() arguments as variables or keywords when unquoted.
|
||||||
cmake_policy(SET CMP0054 NEW)
|
cmake_policy(SET CMP0054 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -65,6 +70,6 @@ if(POLICY CMP0072)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(POLICY CMP0092)
|
if(POLICY CMP0092)
|
||||||
# MSVC warning flags are not in CMAKE_<LANG>_FLAGS by default
|
# MSVC warning flags are not in CMAKE_<LANG>_FLAGS by default.
|
||||||
cmake_policy(SET CMP0092 NEW)
|
cmake_policy(SET CMP0092 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
Reference in New Issue
Block a user