support WANT_ASAN=1 on make command line in linux.370 and macOS.370

When the address sanitizer is in use for gcc, clang, or visual studio,
(-fsanitize=address) define the NetHack preprocessor symbol USING_ADDRESS_SANITIZER.
This commit is contained in:
nhmall
2023-03-29 21:39:44 -04:00
parent cc2410e349
commit d783afbda1
4 changed files with 32 additions and 2 deletions

View File

@@ -72,6 +72,10 @@ endif # WANT_WIN_QT
#-INCLUDE multiw-3.370
ifeq "$(NEED_ASAN)" "1"
LFLAGS +=-fsanitize=address
endif
# NetHack sources control
NHCFLAGS+=-DDLB
NHCFLAGS+=-DHACKDIR=\"$(HACKDIR)\"