diff --git a/cmake/modules/Sanitizers.cmake b/cmake/modules/Sanitizers.cmake --- a/cmake/modules/Sanitizers.cmake +++ b/cmake/modules/Sanitizers.cmake @@ -40,13 +40,13 @@ include(TestSuite) set(SAN_SUPP_DIR "${CMAKE_SOURCE_DIR}/test/sanitizer_suppressions") if("address" IN_LIST ARGN) - add_test_environment(ASAN_OPTIONS malloc_context_size=0) - add_test_environment(LSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/lsan") + add_test_environment(ASAN_OPTIONS "malloc_context_size=0:$ENV{ASAN_OPTIONS}") + add_test_environment(LSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/lsan:$ENV{LSAN_OPTIONS}") endif() if("thread" IN_LIST ARGN) - add_test_environment(TSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/tsan") + add_test_environment(TSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/tsan:$ENV{TSAN_OPTIONS}") endif() if("undefined" IN_LIST ARGN) - add_test_environment(UBSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/ubsan:print_stacktrace=1:halt_on_error=1") + add_test_environment(UBSAN_OPTIONS "suppressions=${SAN_SUPP_DIR}/ubsan:print_stacktrace=1:halt_on_error=1:$ENV{UBSAN_OPTIONS}") endif() endfunction() diff --git a/contrib/teamcity/build-configurations.sh b/contrib/teamcity/build-configurations.sh --- a/contrib/teamcity/build-configurations.sh +++ b/contrib/teamcity/build-configurations.sh @@ -36,10 +36,10 @@ rm -rf "${SAN_LOG_DIR:?}"/* # Sanitizers options, not used if sanitizers are not enabled - export ASAN_OPTIONS="malloc_context_size=0:log_path=${SAN_LOG_DIR}/asan.log" - export LSAN_OPTIONS="suppressions=${SAN_SUPP_DIR}/lsan:log_path=${SAN_LOG_DIR}/lsan.log" - export TSAN_OPTIONS="suppressions=${SAN_SUPP_DIR}/tsan:log_path=${SAN_LOG_DIR}/tsan.log" - export UBSAN_OPTIONS="suppressions=${SAN_SUPP_DIR}/ubsan:print_stacktrace=1:halt_on_error=1:log_path=${SAN_LOG_DIR}/ubsan.log" + export ASAN_OPTIONS="log_path=${SAN_LOG_DIR}/asan.log" + export LSAN_OPTIONS="log_path=${SAN_LOG_DIR}/lsan.log" + export TSAN_OPTIONS="log_path=${SAN_LOG_DIR}/tsan.log" + export UBSAN_OPTIONS="log_path=${SAN_LOG_DIR}/ubsan.log" # Unit test logger parameters UNIT_TESTS_JUNIT_LOG_LEVEL=message