diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2018-07-04 01:20:59 +0200 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2018-07-04 01:22:14 +0200 |
commit | 93c1526bae5ae82d83a24b984e95fee142a47cc3 (patch) | |
tree | 3a3113be1d8e14a0d32f53a0c707bb5ce1ca70a2 | |
parent | 30613a47ae17d3df4ffcb17c91f939b9364846cc (diff) | |
download | tdebase-93c1526bae5ae82d83a24b984e95fee142a47cc3.tar.gz tdebase-93c1526bae5ae82d83a24b984e95fee142a47cc3.zip |
cmake: Use set_property( SOURCE ... COMPILE_DEFINITIONS )
instead of set_source_files_properties( ... COMPILE_FLAGS )
to avoid the problem of double escaping quotation marks.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
(cherry picked from commit 967cf90889abe8df9f6c262319a92a5c8a660f12)
-rw-r--r-- | kcontrol/displayconfig/CMakeLists.txt | 2 | ||||
-rw-r--r-- | kcontrol/dnssd/CMakeLists.txt | 2 | ||||
-rw-r--r-- | kcontrol/hwmanager/CMakeLists.txt | 2 | ||||
-rw-r--r-- | kcontrol/iccconfig/CMakeLists.txt | 2 | ||||
-rw-r--r-- | kcontrol/tdm/CMakeLists.txt | 3 | ||||
-rw-r--r-- | kcontrol/usbview/CMakeLists.txt | 2 | ||||
-rw-r--r-- | kdesktop/CMakeLists.txt | 3 |
7 files changed, 7 insertions, 9 deletions
diff --git a/kcontrol/displayconfig/CMakeLists.txt b/kcontrol/displayconfig/CMakeLists.txt index dfa45882b..a4d26960d 100644 --- a/kcontrol/displayconfig/CMakeLists.txt +++ b/kcontrol/displayconfig/CMakeLists.txt @@ -31,7 +31,7 @@ install( FILES displayconfig.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) ##### kcm_displayconfig (module) #################### -set_source_files_properties( displayconfig.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) +set_property( SOURCE displayconfig.cpp APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) tde_add_kpart( kcm_displayconfig AUTOMOC SOURCES diff --git a/kcontrol/dnssd/CMakeLists.txt b/kcontrol/dnssd/CMakeLists.txt index e0036ba24..527e9f163 100644 --- a/kcontrol/dnssd/CMakeLists.txt +++ b/kcontrol/dnssd/CMakeLists.txt @@ -27,7 +27,7 @@ install( FILES kcm_tdednssd.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) ##### kcm_tdednssd (module) ####################### -set_source_files_properties( kcmdnssd.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) +set_property( SOURCE kcmdnssd.cpp APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) tde_add_kpart( kcm_tdednssd AUTOMOC SOURCES configdialog.ui kcmdnssd.cpp diff --git a/kcontrol/hwmanager/CMakeLists.txt b/kcontrol/hwmanager/CMakeLists.txt index 584eba7bc..cf6fc74b9 100644 --- a/kcontrol/hwmanager/CMakeLists.txt +++ b/kcontrol/hwmanager/CMakeLists.txt @@ -29,7 +29,7 @@ install( FILES hwmanager.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) ##### kcm_iccconfig (module) #################### -set_source_files_properties( hwmanager.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) +set_property( SOURCE hwmanager.cpp APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) tde_add_kpart( kcm_hwmanager AUTOMOC SOURCES diff --git a/kcontrol/iccconfig/CMakeLists.txt b/kcontrol/iccconfig/CMakeLists.txt index 4af3af694..e3b47ce0d 100644 --- a/kcontrol/iccconfig/CMakeLists.txt +++ b/kcontrol/iccconfig/CMakeLists.txt @@ -28,7 +28,7 @@ install( FILES iccconfig.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) ##### kcm_iccconfig (module) #################### -set_source_files_properties( iccconfig.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) +set_property( SOURCE iccconfig.cpp APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) tde_add_kpart( kcm_iccconfig AUTOMOC SOURCES diff --git a/kcontrol/tdm/CMakeLists.txt b/kcontrol/tdm/CMakeLists.txt index 7c2a1f887..4283d0612 100644 --- a/kcontrol/tdm/CMakeLists.txt +++ b/kcontrol/tdm/CMakeLists.txt @@ -29,8 +29,7 @@ install( FILES tdm.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) ##### kcm_tdm (module) ########################## -set_source_files_properties( background.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) -set_source_files_properties( main.cpp PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) +set_property( SOURCE background.cpp main.cpp APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) tde_add_kpart( kcm_tdm AUTOMOC SOURCES diff --git a/kcontrol/usbview/CMakeLists.txt b/kcontrol/usbview/CMakeLists.txt index 1584d0699..61138a72c 100644 --- a/kcontrol/usbview/CMakeLists.txt +++ b/kcontrol/usbview/CMakeLists.txt @@ -26,7 +26,7 @@ link_directories( install( FILES kcmusb.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} ) if( WITH_USBIDS ) - set_source_files_properties( usbdb.cpp PROPERTIES COMPILE_FLAGS -DUSBIDS_FILE=\\"${WITH_USBIDS}\\" ) + set_property( SOURCE usbdb.cpp APPEND PROPERTY COMPILE_DEFINITIONS USBIDS_FILE="${WITH_USBIDS}" ) else( ) install( FILES usb.ids DESTINATION ${DATA_INSTALL_DIR} ) endif( ) diff --git a/kdesktop/CMakeLists.txt b/kdesktop/CMakeLists.txt index fcb84a66a..c8fdabf36 100644 --- a/kdesktop/CMakeLists.txt +++ b/kdesktop/CMakeLists.txt @@ -81,8 +81,7 @@ tde_add_executable( kxdglauncher ##### kdesktop (tdeinit) ######################## set( target kdesktop ) -set_source_files_properties( lockeng.cc PROPERTIES COMPILE_FLAGS -DKDE_CONFDIR=\\"${TDE_CONFIG_DIR}\\" ) - +set_property( SOURCE lockeng.cc APPEND PROPERTY COMPILE_DEFINITIONS KDE_CONFDIR="${TDE_CONFIG_DIR}" ) set( ${target}_SRCS main.cc krootwm.cc xautolock.cc kdiconview.cc init.cc |