hints/linux.370: Add support for ubsan (undefined behaviour sanitizer) for gcc
This will add an option to compile and link nethack executable with ubsan and catch undefined behaviour errors on runtime.
This commit is contained in:
@@ -87,6 +87,11 @@ CFLAGS+=-fsanitize=address
|
||||
LFLAGS+=-fsanitize=address
|
||||
endif
|
||||
|
||||
ifeq "$(USE_UBSAN)" "1"
|
||||
CFLAGS+=-fsanitize=undefined
|
||||
LFLAGS+=-fsanitize=undefined
|
||||
endif
|
||||
|
||||
ifeq "$(USE_CURSESLIB)" "1"
|
||||
# default
|
||||
CURSESLIB = -lncurses -ltinfo
|
||||
|
||||
Reference in New Issue
Block a user