summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2015-03-12 14:58:19 +0000
committerRalf Habacker <ralf.habacker@freenet.de>2015-03-24 08:10:10 +0100
commit21c41b3eb0efb13a118d614336fc41a453d83bfe (patch)
treed098fb8900eeb281ba398ce854acd212c18b68dd /cmake
parent92c39d1d8a30110c5760bd8d5e695e26a8538d1a (diff)
downloaddbus-21c41b3eb0efb13a118d614336fc41a453d83bfe.tar.gz
cmake: only set CMP0053, CMP0054 on CMake >= 3.1
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=89450 Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/CMakeLists.txt6
1 files changed, 4 insertions, 2 deletions
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
index 309cdb2e..0b33ca49 100644
--- a/cmake/CMakeLists.txt
+++ b/cmake/CMakeLists.txt
@@ -14,8 +14,10 @@ endif(COMMAND cmake_policy)
if(CMAKE_MAJOR_VERSION GREATER 2)
cmake_policy(SET CMP0026 NEW)
- cmake_policy(SET CMP0053 NEW)
- cmake_policy(SET CMP0054 NEW)
+ if (CMAKE_MAJOR_VERSION GREATER 4 OR CMAKE_MINOR_VERSION GREATER 1)
+ cmake_policy(SET CMP0053 NEW)
+ cmake_policy(SET CMP0054 NEW)
+ endif()
endif()
# detect version