mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-16 14:28:43 +00:00
Fixed: PCH problems with CMake 2.6
This commit is contained in:
parent
ca7594a9b1
commit
3a506695b9
1 changed files with 12 additions and 2 deletions
|
@ -52,13 +52,23 @@ MACRO(_PCH_GET_COMPILE_FLAGS _out_compile_flags)
|
||||||
LIST(APPEND ${_out_compile_flags} " ${_PCH_include_prefix}\"${item}\"")
|
LIST(APPEND ${_out_compile_flags} " ${_PCH_include_prefix}\"${item}\"")
|
||||||
ENDFOREACH(item)
|
ENDFOREACH(item)
|
||||||
|
|
||||||
|
# Required for CMake 2.6
|
||||||
|
SET(GLOBAL_DEFINITIONS "")
|
||||||
|
GET_DIRECTORY_PROPERTY(DEFINITIONS COMPILE_DEFINITIONS)
|
||||||
|
FOREACH(item ${DEFINITIONS})
|
||||||
|
LIST(APPEND GLOBAL_DEFINITIONS -D${item})
|
||||||
|
ENDFOREACH(item)
|
||||||
|
|
||||||
GET_DIRECTORY_PROPERTY(_directory_flags DEFINITIONS)
|
GET_DIRECTORY_PROPERTY(_directory_flags DEFINITIONS)
|
||||||
GET_DIRECTORY_PROPERTY(_global_definitions DIRECTORY ${CMAKE_SOURCE_DIR} DEFINITIONS)
|
GET_DIRECTORY_PROPERTY(_directory_definitions DIRECTORY ${CMAKE_SOURCE_DIR} DEFINITIONS)
|
||||||
|
LIST(APPEND ${_out_compile_flags} ${GLOBAL_DEFINITIONS})
|
||||||
LIST(APPEND ${_out_compile_flags} ${_directory_flags})
|
LIST(APPEND ${_out_compile_flags} ${_directory_flags})
|
||||||
LIST(APPEND ${_out_compile_flags} ${_global_definitions})
|
LIST(APPEND ${_out_compile_flags} ${_directory_definitions})
|
||||||
LIST(APPEND ${_out_compile_flags} ${CMAKE_CXX_FLAGS})
|
LIST(APPEND ${_out_compile_flags} ${CMAKE_CXX_FLAGS})
|
||||||
|
|
||||||
|
# Format definitions and remove duplicates
|
||||||
SEPARATE_ARGUMENTS(${_out_compile_flags})
|
SEPARATE_ARGUMENTS(${_out_compile_flags})
|
||||||
|
LIST(REMOVE_DUPLICATES ${_out_compile_flags})
|
||||||
ENDMACRO(_PCH_GET_COMPILE_FLAGS)
|
ENDMACRO(_PCH_GET_COMPILE_FLAGS)
|
||||||
|
|
||||||
MACRO(_PCH_GET_PDB_FILENAME out_filename _target)
|
MACRO(_PCH_GET_PDB_FILENAME out_filename _target)
|
||||||
|
|
Loading…
Reference in a new issue