mirror of
https://github.com/RPCS3/glslang.git
synced 2024-11-23 19:29:44 +00:00
Fix option replacement when flags are empty
For the scenario when cmake is executed from MSVC with empty CXX flags. Signed-off-by: Denis Zalevskiy <denis.zalevskiy@basemark.com>
This commit is contained in:
parent
9325cc013e
commit
78dbd7514a
@ -186,7 +186,7 @@ elseif(MSVC)
|
||||
if(NOT ENABLE_RTTI)
|
||||
string(FIND "${CMAKE_CXX_FLAGS}" "/GR" MSVC_HAS_GR)
|
||||
if(MSVC_HAS_GR)
|
||||
string(REGEX REPLACE /GR /GR- CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
|
||||
string(REGEX REPLACE "/GR" "/GR-" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
|
||||
else()
|
||||
add_compile_options(/GR-) # Disable RTTI
|
||||
endif()
|
||||
|
Loading…
Reference in New Issue
Block a user