gudhi-devel
gudhi-devel copied to clipboard
Feature/sanitizer option
A new cmake gudhi option to activate gcc/clang sanitizers. Default value is WITH_GUDHI_SANITIZER=''
.
In a command line one can easily activate sanitizer with i.e.:
cmake -DWITH_GUDHI_SANITIZER=address .
This will activate debug mode (-g
) and add the compilation flag -fsanitize=addess
.
With MSVC, a warning message to explain the feature is not available is displayed.
It does not activate sanitizer for the python module. To be discussed.
With MSVC, a warning message to explain the feature is not available is displayed.
https://docs.microsoft.com/en-us/cpp/sanitizers/asan ?
With MSVC, a warning message to explain the feature is not available is displayed.
https://docs.microsoft.com/en-us/cpp/sanitizers/asan ?
Sorry, I didn't know it was available under MSVC. I made the change on 6b373b8 and tested it under Windows.
cmake -DCMAKE_CXX_FLAGS=-fsanitize=address .
Not that much, you are right.
Maybe a better way would be to add a how_to_compile_gudhi_with_sanitizers.md
(or a better name) in order to explain to contributors how to deal with it.