build: added sitl-asan build target

this enables the address sanitiser for array bounds error detection
This commit is contained in:
Andrew Tridgell 2015-11-10 16:21:41 +11:00
parent 577670ccee
commit 3d8993ff33

View File

@ -74,6 +74,10 @@ empty: all
# support debug build
%-debug: OPTFLAGS = -g -O0
# support address sanitiser
%-asan: OPTFLAGS = -g -O0 -fsanitize=address -fno-omit-frame-pointer
%-asan: LDFLAGS += -fsanitize=address
# cope with -nologging
%-nologging: EXTRAFLAGS += "-DLOGGING_ENABLED=DISABLED "
@ -94,6 +98,7 @@ endef
define board_template
$(1)-hil : $(1)
$(1)-debug : $(1)
$(1)-asan : $(1)
$(1)-hilsensors : $(1)
endef