CMake: Win: Disable fastlink for VS2026

This option has been removed in vs2026 and will cause a build error,
disabling this option results in our default /DEBUG being used
which is equivalent to /debug:full which is the suggested
replacement
This commit is contained in:
Ray Molenkamp
2025-09-11 11:45:25 -06:00
parent bef15f0ec1
commit eccb7fddb0

View File

@@ -295,9 +295,13 @@ endif()
string(APPEND PLATFORM_LINKFLAGS " /SUBSYSTEM:CONSOLE /STACK:2097152")
set(PLATFORM_LINKFLAGS_RELEASE "/NODEFAULTLIB:libcmt.lib /NODEFAULTLIB:libcmtd.lib /NODEFAULTLIB:msvcrtd.lib")
if(NOT WITH_COMPILER_ASAN)
# ASAN is incompatible with `fastlink`, it will appear to work,
# but will not resolve symbols which makes it somewhat useless.
if(
(NOT WITH_COMPILER_ASAN) AND
# ASAN is incompatible with `fastlink`, it will appear to work,
# but will not resolve symbols which makes it somewhat useless.
MSVC_VERSION LESS 1950
# /debug:fastlink is no longer supported in vs2026
)
string(APPEND PLATFORM_LINKFLAGS_DEBUG "/debug:fastlink ")
endif()
string(APPEND PLATFORM_LINKFLAGS_DEBUG " /IGNORE:4099 /NODEFAULTLIB:libcmt.lib /NODEFAULTLIB:msvcrt.lib /NODEFAULTLIB:libcmtd.lib")