diff options
author | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-07-03 18:20:32 +0200 |
---|---|---|
committer | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-07-03 18:21:58 +0200 |
commit | 966eb6646450fec69cbd4b314d1c48afdfcd6330 (patch) | |
tree | 4b1f9b7f3c1a9141644e00fe57080812fdde6079 /Makefile | |
parent | d9743696562fc85643e016d778ee994f0b9296db (diff) | |
download | cpp-utils-966eb6646450fec69cbd4b314d1c48afdfcd6330.tar.gz cpp-utils-966eb6646450fec69cbd4b314d1c48afdfcd6330.zip |
enable asa/lsan/ubsan
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -8,10 +8,11 @@ DEPS = $(TEST:%=build/%.d) # -- FLAGS --------------------------------------------------------------------- -DEPS_GEN = -MMD -CXXFLAGS = -g -Wall -Wextra -Werror -I. -std=c++14 $(DEPS_GEN) +DEPS_GEN = -MMD +SANITIZER = -fsanitize=address -fsanitize=undefined -fsanitize=leak -fno-omit-frame-pointer -# -- RULES --------------------------------------------------------------------- +CXXFLAGS = -Og -g -Wall -Wextra -Werror -I. -std=c++14 $(DEPS_GEN) $(SANITIZER) +LDFLAGS = $(SANITIZER) all: build $(BINS) @@ -20,7 +21,7 @@ bear: bear citnames build/%: build/%.o - $(CXX) -o $@ $< + $(CXX) -o $@ $< $(LDFLAGS) build/%.o: test/%.cc $(CXX) -c -o $@ $< $(CXXFLAGS) |