From e26ae5c981fa82d3df622584c4b6a1d8965e5681 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Wed, 11 May 2022 21:49:27 +0200 Subject: [PATCH] boards/native: split out asan CFLAGS_ASAN, LINKFLAGS_ASAN --- boards/native/Makefile.include | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/boards/native/Makefile.include b/boards/native/Makefile.include index 5a3dd0a60b..739870296c 100644 --- a/boards/native/Makefile.include +++ b/boards/native/Makefile.include @@ -132,9 +132,11 @@ all-valgrind: CFLAGS += -DHAVE_VALGRIND_H all-valgrind: NATIVEINCLUDES += $(shell pkg-config valgrind --cflags) all-gprof: CFLAGS += -pg all-gprof: LINKFLAGS += -pg -all-asan: CFLAGS += -fsanitize=address -fno-omit-frame-pointer -all-asan: CFLAGS += -DNATIVE_MEMORY -all-asan: LINKFLAGS += -fsanitize=address -fno-omit-frame-pointer + +CFLAGS_ASAN += -fsanitize=address -fno-omit-frame-pointer -DNATIVE_MEMORY +LINKFLAGS_ASAN += -fsanitize=address -fno-omit-frame-pointer +all-asan: CFLAGS += $(CFLAGS_ASAN) +all-asan: LINKFLAGS += $(LINKFLAGS_ASAN) all-asan: export AFL_USE_ASAN=1 INCLUDES += $(NATIVEINCLUDES)