cmake: eliminate warning about policy on cmake 3.1

This commit is contained in:
Vladimir Timofeev 2015-01-26 10:15:41 +03:00 committed by Vladimir Timofeev
parent b6201f9328
commit 86f57f11c6
1 changed files with 6 additions and 0 deletions

View File

@ -29,6 +29,12 @@ cmake_minimum_required(VERSION 2.8)
# also from cmake's Modules dir, to not clash with per-project files.
cmake_policy(SET CMP0017 NEW)
# Use new behaviour with cmake >= 3.0:
# Only interpret if() arguments as variables or keywords when unquoted.
if(CMAKE_VERSION VERSION_GREATER 3)
cmake_policy(SET CMP0054 NEW)
endif()
project (Cocos2d-X)
# The version number