explicitly undefine NDEBUG in CFLAGS.

This commit is contained in:
2025-06-23 13:19:06 +02:00
parent f78a5b6557
commit 3e4d16a5be

View File

@@ -24,21 +24,21 @@ ISWIN := $(if $(filter linux darwin freebsd netbsd openbsd,$(KERNEL)),0,1)
# profiles
ifeq ($(DEBUG),1) # check whether we're debugging
CFLAGS += -Og -g
CFLAGS += -UNDEBUG -Og -g
PROF := dbg
ifeq ($(ISWIN),0)
CFLAGS += -fsanitize=address,undefined
LDFLAGS += -fsanitize=address,undefined
endif
else ifeq ($(DEBUG),test) # check whether we're perhaps testing
CFLAGS += -O2 -g
CFLAGS += -UNDEBUG -O2 -g
PROF := test
ifeq ($(ISWIN),0)
CFLAGS += -fsanitize=address
LDFLAGS += -fsanitize=address
endif
else # otherwise, assume release
CFLAGS += -O2 -DNDEBUG
CFLAGS += -DNDEBUG -O2
PROF := rel
endif