aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2008-02-20 21:38:34 +0000
committerAlexander Neundorf <neundorf@kde.org>2008-02-20 21:38:34 +0000
commitc0c75cf957d5e7aef30c9c59c27a6ccc760d60c5 (patch)
treec407072d430c4315bd960d08fcecc73e6616aaae /modules
parent493aa49d3e73cf0a191f5e13afd822dfbfe8fd79 (diff)
downloadextra-cmake-modules-c0c75cf957d5e7aef30c9c59c27a6ccc760d60c5.tar.gz
extra-cmake-modules-c0c75cf957d5e7aef30c9c59c27a6ccc760d60c5.tar.bz2
-give a useful error message if somebody is using an old cmake cvs, which doesn't have set_property() yet
Alex svn path=/trunk/KDE/kdelibs/; revision=777542
Diffstat (limited to 'modules')
-rw-r--r--modules/FindKDE4Internal.cmake12
1 files changed, 8 insertions, 4 deletions
diff --git a/modules/FindKDE4Internal.cmake b/modules/FindKDE4Internal.cmake
index dcde0cf0..fb1b3f1d 100644
--- a/modules/FindKDE4Internal.cmake
+++ b/modules/FindKDE4Internal.cmake
@@ -655,11 +655,15 @@ if(WIN32)
endif(WIN32)
-# CMake 2.6 gives errors if there are multiple targets with the same name
-# we use this for the target "buildtests", which is created for the unit tests
-# and which depends on the tests, so building "buildtests" builds all the tests
-# enabling this property disables this check in CMake
if("${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}" GREATER 2.4)
+ if(NOT COMMAND SET_PROPERTY)
+ message(FATAL_ERROR "You are using an old version of CMake from cvs, please update to CMake >= 2.6.0 or cvs at least from Feb 20th, 2008")
+ endif(NOT COMMAND SET_PROPERTY)
+
+ # CMake 2.6 gives errors if there are multiple targets with the same name
+ # we use this for the target "buildtests", which is created for the unit tests
+ # and which depends on the tests, so building "buildtests" builds all the tests
+ # enabling this property disables this check in CMake
set_property(GLOBAL PROPERTY ALLOW_DUPLICATE_CUSTOM_TARGETS 1)
endif("${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}" GREATER 2.4)