Files @ r28292:edbeb8d2786a
Branch filter:

Location: cpp/openttd-patchpack/source/cmake/Static.cmake

Peter Nelson
Fix #11585: Crash when cleaning AI/GS with nested AsyncMode.

Do not throw sanity check when in_shutdown is true. This is also applied to
ExecMode and TestMode as they follow the same pattern.
# Set static linking if the platform requires it.
#
# set_static()
#
function(set_static_if_needed)
     if(MINGW)
        # Let exectutables run outside MinGW environment
        # Force searching static libs
        set(CMAKE_FIND_LIBRARY_SUFFIXES ".a" PARENT_SCOPE)

        # Force static linking
        link_libraries(-static -static-libgcc -static-libstdc++)
    endif()
endfunction()