cmake: only MSVC understands -nodefaultlib:MSVCRT

This commit is contained in:
Anonymous Maarten 2022-11-26 03:18:27 +01:00 committed by Anonymous Maarten
parent 5151cbf4d1
commit 3acd1ad25f
1 changed files with 1 additions and 1 deletions

View File

@ -3246,7 +3246,7 @@ if(SDL_SHARED)
add_library(SDL3::SDL3 ALIAS SDL3) add_library(SDL3::SDL3 ALIAS SDL3)
set_target_properties(SDL3 PROPERTIES POSITION_INDEPENDENT_CODE TRUE) set_target_properties(SDL3 PROPERTIES POSITION_INDEPENDENT_CODE TRUE)
if(NOT SDL_LIBC) if(NOT SDL_LIBC)
if(SDL_CPU_X86) if(MSVC AND SDL_CPU_X86)
# FIXME: should be added for all architectures (missing symbols for ARM) # FIXME: should be added for all architectures (missing symbols for ARM)
target_link_libraries(SDL3 PRIVATE "-nodefaultlib:MSVCRT") target_link_libraries(SDL3 PRIVATE "-nodefaultlib:MSVCRT")
endif() endif()