Всегда проверять флаги для динамического анализа

This commit is contained in:
Andrei Astafev 2021-06-12 14:57:25 +03:00
parent f1ebe75238
commit 9b8b4fa98e
3 changed files with 3 additions and 9 deletions

View File

@ -34,9 +34,7 @@ set(FLAG_CANDIDATES
# add some handy functions
include(sanitize-helpers)
if(SANITIZE_CFI)
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "ControlFlowIntegrity" "CFI")
endif()
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "ControlFlowIntegrity" "CFI")
function(add_sanitize_cfi TARGET)
sanitizer_check_target(${TARGET})

View File

@ -29,9 +29,7 @@ set(FLAG_CANDIDATES "-g -fsanitize=leak")
include(sanitize-helpers)
if(SANITIZE_LEAK)
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "LeakSanitizer" "LeakSan")
endif()
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "LeakSanitizer" "LeakSan")
function(add_sanitize_leak TARGET)
sanitizer_check_target(${TARGET})

View File

@ -29,9 +29,7 @@ set(FLAG_CANDIDATES "-g -fsanitize=safe-stack")
# add some handy functions
include(sanitize-helpers)
if(SANITIZE_SS)
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "SafeStack" "SS")
endif()
sanitizer_check_compiler_flags("${FLAG_CANDIDATES}" "SafeStack" "SS")
function(add_sanitize_ss TARGET)
sanitizer_check_target(${TARGET})