build: fix libgcc_s.so.1 issue

This commit is contained in:
tobtoht 2024-04-29 04:13:04 +02:00
parent c5b46211b8
commit 26420efbfd
No known key found for this signature in database
GPG key ID: E45B10DD027D2472

View file

@ -287,10 +287,13 @@ if (WIN32)
endif()
if(STATIC)
# add_linker_flag_if_supported(-static-libgcc STATIC_FLAGS)
# add_linker_flag_if_supported(-static-libstdc++ STATIC_FLAGS)
if(MINGW)
add_linker_flag_if_supported(-static STATIC_FLAGS)
elseif (NOT (APPLE OR FREEBSD OR OPENBSD OR DRAGONFLY))
if(NOT "${ARCH}" STREQUAL "armv7-a")
add_linker_flag_if_supported(-static-libgcc STATIC_FLAGS)
add_linker_flag_if_supported(-static-libstdc++ STATIC_FLAGS)
endif()
endif()
endif()