stdlib: move all mslibc functions to SDL_mslibc.c

This allows disabling LTO on them by only specifying a single file.
This commit is contained in:
Anonymous Maarten
2022-07-26 21:47:52 +02:00
committed by Sam Lantinga
parent a169259f62
commit 5da85376b9
12 changed files with 829 additions and 894 deletions

View File

@@ -678,7 +678,8 @@ endif()
if(MSVC)
# Due to a limitation of Microsoft's LTO implementation, LTO must be disabled for memcpy and memset.
set_property(SOURCE src/stdlib/SDL_memcpy.c src/stdlib/SDL_memset.c APPEND PROPERTY COMPILE_FLAGS /GL-)
# The same applies to various functions normally belonging in the C library (for x86 architecture).
set_property(SOURCE src/stdlib/SDL_mslibc.c APPEND PROPERTY COMPILE_FLAGS /GL-)
endif()
if(SDL_ASSEMBLY)