Better fix for _FORTIFY_SOURCE

This commit is contained in:
Our Favorite Fruit 2024-03-05 05:47:13 +01:00
parent 4f62cf9011
commit a061457cda

View file

@ -117,8 +117,7 @@ else()
if (NOT CMAKE_BUILD_TYPE STREQUAL Debug) if (NOT CMAKE_BUILD_TYPE STREQUAL Debug)
# _FORTIFY_SOURCE can't be used without optimizations. # _FORTIFY_SOURCE can't be used without optimizations.
add_compile_options(-Wp,-U_FORTIFY_SOURCE) add_compile_options(-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1)
add_compile_options(-Wp,-D_FORTIFY_SOURCE=2)
endif() endif()
if (CITRA_WARNINGS_AS_ERRORS) if (CITRA_WARNINGS_AS_ERRORS)