Fixed: CMake definitions in PCH

--HG--
branch : develop
feature/pipeline-tools
kervala 8 years ago
parent 6162352d8b
commit 5ee53205b9

@ -28,15 +28,12 @@ ELSE()
ENDIF() ENDIF()
MACRO(APPEND_DEFINITION _NAME _VAL) MACRO(APPEND_DEFINITION _NAME _VAL)
# value is not empty IF(CMAKE_VERSION VERSION_LESS "2.8.12")
IF(${_VAL}) # don't support logical expressions, append definition
IF(CMAKE_VERSION VERSION_LESS "2.8.12") LIST(APPEND ${_NAME} "-D${_VAL}")
# don't support logical expressions, append definition ELSE()
LIST(APPEND ${_NAME} "-D${_VAL}") # support logical expressions, use them
ELSE() LIST(APPEND ${_NAME} "$<$<BOOL:${_VAL}>:-D$<JOIN:${_VAL},-D>>")
# support logical expressions, use them
LIST(APPEND ${_NAME} "$<$<BOOL:${_VAL}>:-D$<JOIN:${_VAL},-D>>")
ENDIF()
ENDIF() ENDIF()
ENDMACRO() ENDMACRO()

Loading…
Cancel
Save