Browse Source

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>
Michele Calgaro 7 months ago
parent
commit
c1b7409de9
2 changed files with 3 additions and 3 deletions
  1. 2
    2
      artsc/CMakeLists.txt
  2. 1
    1
      soundserver/CMakeLists.txt

+ 2
- 2
artsc/CMakeLists.txt View File

@@ -86,7 +86,7 @@ tde_add_library( artsdsp_st SHARED
86 86
   DESTINATION ${LIB_INSTALL_DIR}
87 87
 )
88 88
 
89
-set_target_properties( artsdsp_st-shared PROPERTIES COMPILE_FLAGS -DARTSC_BACKEND=\\"${LIB_INSTALL_DIR}/libartscbackend.la\\" )
89
+set_property( TARGET artsdsp_st-shared APPEND PROPERTY COMPILE_DEFINITIONS ARTSC_BACKEND="${LIB_INSTALL_DIR}/libartscbackend.la" )
90 90
 
91 91
 
92 92
 ##### artsc (shared lib) ########################
@@ -98,7 +98,7 @@ tde_add_library( artsc SHARED
98 98
   DESTINATION ${LIB_INSTALL_DIR}
99 99
 )
100 100
 
101
-set_target_properties( artsc-shared PROPERTIES COMPILE_FLAGS -DARTSC_BACKEND=\\"${LIB_INSTALL_DIR}/libartscbackend.la\\" )
101
+set_property( TARGET artsc-shared APPEND PROPERTY COMPILE_DEFINITIONS ARTSC_BACKEND="${LIB_INSTALL_DIR}/libartscbackend.la" )
102 102
 
103 103
 
104 104
 ##### artscbackend (shared lib) #################

+ 1
- 1
soundserver/CMakeLists.txt View File

@@ -165,7 +165,7 @@ tde_add_executable( artswrapper
165 165
 # FIXME "artsdpath" seems inconsistent name
166 166
 # necessary for artswrapper
167 167
 SET( artsdpath  ${BIN_INSTALL_DIR}/artsd )
168
-set_target_properties( artswrapper PROPERTIES COMPILE_FLAGS -DEXECUTE=\\"${artsdpath}\\" )
168
+set_property( TARGET artswrapper APPEND PROPERTY COMPILE_DEFINITIONS EXECUTE="${artsdpath}" )
169 169
 
170 170
 
171 171
 ##### artsshell #################################

Loading…
Cancel
Save