mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-11-22 11:40:05 +00:00
Fix link flags for Clang-based MinGW cross compile (#5342)
See https://github.com/android/ndk/issues/1464 The old code tested for Windows and GCC as the compiler. Instead of checking for GCC, check the compiler is not MSVC.
This commit is contained in:
parent
2813da2681
commit
c50bc49f58
@ -243,7 +243,7 @@ function(spvtools_default_compile_options TARGET)
|
||||
# For MinGW cross compile, statically link to the C++ runtime.
|
||||
# But it still depends on MSVCRT.dll.
|
||||
if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
|
||||
if (${CMAKE_CXX_COMPILER_ID} MATCHES "GNU")
|
||||
if (NOT MSVC)
|
||||
set_target_properties(${TARGET} PROPERTIES
|
||||
LINK_FLAGS -static -static-libgcc -static-libstdc++)
|
||||
endif()
|
||||
|
Loading…
Reference in New Issue
Block a user