cmake: fix compilation with MSAN and enable origin tracking

master
Andre Puschmann 3 years ago
parent 80a89ec4bf
commit 5d238a6d80

@ -491,8 +491,8 @@ if(CMAKE_C_COMPILER_ID MATCHES "GNU" OR CMAKE_C_COMPILER_ID MATCHES "Clang")
endif (ENABLE_TSAN) endif (ENABLE_TSAN)
if (ENABLE_MSAN AND CMAKE_C_COMPILER_ID MATCHES "Clang") if (ENABLE_MSAN AND CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=memory -fno-omit-frame-pointer -fPIE -pie") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=memory -fno-omit-frame-pointer -fsanitize-memory-track-origins -fPIE")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=memory -fno-omit-frame-pointer -fPIE -pie") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=memory -fno-omit-frame-pointer -fsanitize-memory-track-origins -fPIE")
endif (ENABLE_MSAN AND CMAKE_C_COMPILER_ID MATCHES "Clang") endif (ENABLE_MSAN AND CMAKE_C_COMPILER_ID MATCHES "Clang")
if (ENABLE_GCOV) if (ENABLE_GCOV)

Loading…
Cancel
Save