3
0
mirror of https://github.com/triqs/dft_tools synced 2024-08-06 20:40:00 +02:00

[cmake] Add a warning if ASAN/UBSAN is used without Build_Deps=Always

This commit is contained in:
Nils Wentzell 2020-05-01 14:28:44 -04:00
parent 0394f7fae2
commit 0ebc5a3f73

3
deps/CMakeLists.txt vendored
View File

@ -41,6 +41,9 @@ else()
message(FATAL_ERROR "Build_Deps option should be either 'Never', 'Always' or 'IfNotFound'")
endif()
set(Build_Deps ${Build_Deps} CACHE STRING "Do we build dependencies from source? [Never/Always/IfNotFound]")
if(NOT IS_SUBPROJECT AND NOT Build_Deps STREQUAL "Always" AND (ASAN OR UBSAN))
message(WARNING "For builds with llvm sanitizers (ASAN/UBSAN) it is recommended to use -DBuild_Deps=Always to avoid false positives.")
endif()
endif()
# -- GTest --