Avoid passing sanitizer options to MSVC linker

Apparently it does not support them
This commit is contained in:
ISSOtm
2026-03-16 11:29:25 +01:00
committed by Rangi
parent d8722b6705
commit 10e1c9d187

View File

@@ -45,9 +45,7 @@ if(MSVC)
if(SANITIZERS) if(SANITIZERS)
message(STATUS "ASan enabled") message(STATUS "ASan enabled")
set(SAN_FLAGS /fsanitize=address) add_compile_options(/fsanitize=address) # Note that this shouldn't be passed to the linker.
add_compile_options(${SAN_FLAGS})
add_link_options(${SAN_FLAGS})
endif() endif()
else() else()
add_compile_options(-Wall -pedantic -fno-exceptions -fno-rtti add_compile_options(-Wall -pedantic -fno-exceptions -fno-rtti