#2861: If compiling with macOS and GCC, default ENABLE_PCH to false since CMake will generate incompatible Xarch flags for the precompiled headers
This commit is contained in:
parent
66ac0df61b
commit
ab87ffe7cf
@ -106,7 +106,14 @@ CMAKE_DEPENDENT_OPTION(ENABLE_HLSL
|
|||||||
option(ENABLE_RTTI "Enables RTTI" OFF)
|
option(ENABLE_RTTI "Enables RTTI" OFF)
|
||||||
option(ENABLE_EXCEPTIONS "Enables Exceptions" OFF)
|
option(ENABLE_EXCEPTIONS "Enables Exceptions" OFF)
|
||||||
option(ENABLE_OPT "Enables spirv-opt capability if present" ON)
|
option(ENABLE_OPT "Enables spirv-opt capability if present" ON)
|
||||||
|
|
||||||
|
if (CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND ${CMAKE_CXX_COMPILER_ID} MATCHES "GNU")
|
||||||
|
# Workaround for CMake behavior on Mac OS with gcc, cmake generates -Xarch_* arguments
|
||||||
|
# which gcc rejects
|
||||||
|
option(ENABLE_PCH "Enables Precompiled header" OFF)
|
||||||
|
else()
|
||||||
option(ENABLE_PCH "Enables Precompiled header" ON)
|
option(ENABLE_PCH "Enables Precompiled header" ON)
|
||||||
|
endif()
|
||||||
option(ENABLE_CTEST "Enables testing" ON)
|
option(ENABLE_CTEST "Enables testing" ON)
|
||||||
|
|
||||||
if(ENABLE_GLSLANG_INSTALL AND CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND WIN32)
|
if(ENABLE_GLSLANG_INSTALL AND CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND WIN32)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user