summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Kelly <[email protected]>2015-07-19 21:38:38 +0200
committerStephen Kelly <[email protected]>2015-07-19 21:38:38 +0200
commitcf80c7a1652597504260d0fc2e62c90e17b5f4bd (patch)
tree5bc2e72ebaee24cb81c1eade9832bbb8b8b8dd1b
parent5657d6846cda960b4bf05d1abf01180bf63bf76f (diff)
Fix CMP0005 warnings.
-rw-r--r--cmake/modules/FindKDE4Internal.cmake4
-rw-r--r--kfile/tests/CMakeLists.txt2
-rw-r--r--knewstuff/tests/CMakeLists.txt2
-rw-r--r--kutils/kemoticons/tests/CMakeLists.txt2
-rw-r--r--plasma/private/qtjolie-branch/tests/CMakeLists.txt4
-rw-r--r--solid/tests/CMakeLists.txt6
6 files changed, 10 insertions, 10 deletions
diff --git a/cmake/modules/FindKDE4Internal.cmake b/cmake/modules/FindKDE4Internal.cmake
index 6f03eae..c277049 100644
--- a/cmake/modules/FindKDE4Internal.cmake
+++ b/cmake/modules/FindKDE4Internal.cmake
@@ -361,8 +361,8 @@ cmake_policy(SET CMP0000 OLD)
cmake_policy(SET CMP0002 OLD)
# CMP0003: add the link paths to the link command as with cmake 2.4
cmake_policy(SET CMP0003 OLD)
-# CMP0005: keep escaping behaviour for definitions added via add_definitions()
-cmake_policy(SET CMP0005 OLD)
+
+cmake_policy(SET CMP0005 NEW)
# since cmake 2.6.3: NEW behaviour is that setting policies doesn't "escape" the file
# where this is done, macros and functions are executed with the policies as they
# were when the were defined. Keep the OLD behaviour so we can set the policies here
diff --git a/kfile/tests/CMakeLists.txt b/kfile/tests/CMakeLists.txt
index 37eca31..fa872a4 100644
--- a/kfile/tests/CMakeLists.txt
+++ b/kfile/tests/CMakeLists.txt
@@ -19,7 +19,7 @@ KFILE_EXECUTABLE_TESTS(
kfiletreeviewtest
)
-add_definitions(-DTEST_DATA="\\"${CMAKE_SOURCE_DIR}/solid/solid/backends/fakehw/fakecomputer.xml\\"")
+add_definitions(-DTEST_DATA="${CMAKE_SOURCE_DIR}/solid/solid/backends/fakehw/fakecomputer.xml")
KFILE_UNIT_TESTS(
kfileplacesmodeltest
diff --git a/knewstuff/tests/CMakeLists.txt b/knewstuff/tests/CMakeLists.txt
index c3eb5e8..898add2 100644
--- a/knewstuff/tests/CMakeLists.txt
+++ b/knewstuff/tests/CMakeLists.txt
@@ -5,7 +5,7 @@ include_directories(${KDE4_KIO_INCLUDES} ${CMAKE_CURRENT_BINARY_DIR}/..
${CMAKE_CURRENT_SOURCE_DIR}/.. ${CMAKE_CURRENT_BINARY_DIR}/../knewstuff2/
${CMAKE_CURRENT_SOURCE_DIR}/../knewstuff2/)
-add_definitions(-DKNSSRCDIR=\\""${CMAKE_CURRENT_SOURCE_DIR}"\\" -DKNSBUILDDIR=\\""${CMAKE_CURRENT_BINARY_DIR}"\\")
+add_definitions(-DKNSSRCDIR="${CMAKE_CURRENT_SOURCE_DIR}" -DKNSBUILDDIR="${CMAKE_CURRENT_BINARY_DIR}")
set(CMAKE_SKIP_RPATH TRUE)
##########################
diff --git a/kutils/kemoticons/tests/CMakeLists.txt b/kutils/kemoticons/tests/CMakeLists.txt
index e6a7c60..ea0ae37 100644
--- a/kutils/kemoticons/tests/CMakeLists.txt
+++ b/kutils/kemoticons/tests/CMakeLists.txt
@@ -5,7 +5,7 @@ include_directories(${CMAKE_SOURCE_DIR} ../ ${CMAKE_CURRENT_BINARY_DIR})
kde4_add_executable(kemoticonstest main.cpp)
target_link_libraries(kemoticonstest ${KDE4_KDEUI_LIBS} kemoticons)
-add_definitions( -DSRCDIR="\\"${CMAKE_CURRENT_SOURCE_DIR}/\\"" )
+add_definitions( -DSRCDIR="${CMAKE_CURRENT_SOURCE_DIR}/" )
set(kemoticontest2_SRCS kemoticontest.cpp)
kde4_add_unit_test(kemoticontest2 TESTNAME kutils-kemoticontest2 ${kemoticontest2_SRCS})
target_link_libraries(kemoticontest2 ${QT_QTTEST_LIBRARY} ${KDE4_KIO_LIBS} kemoticons)
diff --git a/plasma/private/qtjolie-branch/tests/CMakeLists.txt b/plasma/private/qtjolie-branch/tests/CMakeLists.txt
index de41ef9..5aa4472 100644
--- a/plasma/private/qtjolie-branch/tests/CMakeLists.txt
+++ b/plasma/private/qtjolie-branch/tests/CMakeLists.txt
@@ -4,7 +4,7 @@ MACRO(SODEP_UNIT_TESTS)
FOREACH(_testname ${ARGN})
kde4_add_unit_test(${_testname} TESTNAME plasma-sodep-${_testname} NOGUI ${_testname}.cpp)
target_link_libraries(${_testname} ${QT_QTCORE_LIBRARY} ${QT_QTTEST_LIBRARY} ${QT_QTNETWORK_LIBRARY} QtJolie)
- add_definitions(-DDATA_DIR="\\"${CMAKE_CURRENT_SOURCE_DIR}\\"")
+ add_definitions(-DDATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}")
ENDFOREACH(_testname)
ENDMACRO(SODEP_UNIT_TESTS)
@@ -12,7 +12,7 @@ MACRO(SODEP_EXECUTABLE_TESTS)
FOREACH(_testname ${ARGN})
kde4_add_executable(${_testname} NOGUI TEST ${_testname}.cpp)
target_link_libraries(${_testname} ${QT_QTCORE_LIBRARY} ${QT_QTGUI_LIBRARY} ${QT_QTNETWORK_LIBRARY} QtJolie)
- add_definitions(-DDATA_DIR="\\"${CMAKE_CURRENT_SOURCE_DIR}\\"")
+ add_definitions(-DDATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}")
ENDFOREACH(_testname)
ENDMACRO(SODEP_EXECUTABLE_TESTS)
diff --git a/solid/tests/CMakeLists.txt b/solid/tests/CMakeLists.txt
index ef507d1..f558016 100644
--- a/solid/tests/CMakeLists.txt
+++ b/solid/tests/CMakeLists.txt
@@ -13,7 +13,7 @@ if(WIN32)
endif(WIN32)
target_link_libraries(fakehardwaretest solid_static ${QT_QTCORE_LIBRARY} ${QT_QTDBUS_LIBRARY} ${QT_QTXML_LIBRARY} ${QT_QTTEST_LIBRARY} )
-add_definitions(-DTEST_DATA="\\"${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml\\"")
+add_definitions(-DTEST_DATA="${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml")
########### halbasictest ###############
@@ -37,7 +37,7 @@ set(solidhwtest_SRCS
kde4_add_unit_test(solidhwtest ${solidhwtest_SRCS})
-add_definitions(-DFAKE_COMPUTER_XML="\\"${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml\\"")
+add_definitions(-DFAKE_COMPUTER_XML="${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml")
include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw )
@@ -55,7 +55,7 @@ set(solidmttest_SRCS
kde4_add_unit_test(solidmttest ${solidmttest_SRCS})
-add_definitions(-DFAKE_COMPUTER_XML="\\"${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml\\"")
+add_definitions(-DFAKE_COMPUTER_XML="${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw/fakecomputer.xml")
include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../solid/backends/fakehw )