mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-27 01:26:30 +00:00
Fixed: Define QT_NO_DEBUG in Release with Qt 5 also in PCH
This commit is contained in:
parent
3b32412d2a
commit
501f31e03b
1 changed files with 14 additions and 11 deletions
|
@ -145,13 +145,15 @@ MACRO(PCH_SET_COMPILE_FLAGS _target)
|
|||
ENDFOREACH()
|
||||
ENDIF()
|
||||
|
||||
# Special Qt 5 cases
|
||||
IF(GLOBAL_DEFINITIONS MATCHES "QT_CORE_LIB")
|
||||
# Hack to define missing QT_NO_DEBUG with Qt 5.2
|
||||
IF(USE_QT5 AND _UPPER_BUILD STREQUAL "RELEASE")
|
||||
IF(_UPPER_BUILD STREQUAL "RELEASE")
|
||||
LIST(APPEND GLOBAL_DEFINITIONS " -DQT_NO_DEBUG")
|
||||
ENDIF()
|
||||
|
||||
# Qt5_POSITION_INDEPENDENT_CODE should be true if Qt was compiled with PIE
|
||||
IF(Qt5_POSITION_INDEPENDENT_CODE AND GLOBAL_DEFINITIONS MATCHES "QT_CORE_LIB")
|
||||
IF(Qt5_POSITION_INDEPENDENT_CODE)
|
||||
SET(_USE_PIE ON)
|
||||
ENDIF()
|
||||
|
||||
|
@ -159,6 +161,7 @@ MACRO(PCH_SET_COMPILE_FLAGS _target)
|
|||
LIST(APPEND _FLAGS " ${CMAKE_CXX_COMPILE_OPTIONS_PIE}")
|
||||
LIST(APPEND _FLAGS " ${CMAKE_CXX_COMPILE_OPTIONS_PIC}")
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
|
||||
LIST(APPEND _FLAGS " ${GLOBAL_DEFINITIONS}")
|
||||
|
||||
|
|
Loading…
Reference in a new issue