From a6ec8cf83d770598961d3081d23fa8d3cd7b70ac Mon Sep 17 00:00:00 2001 From: Quinn Date: Sat, 14 Jun 2025 23:20:23 +0200 Subject: [PATCH] fix: windows compilation because it doesn't support sanitisers --- makefile | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/makefile b/makefile index 9928730..d3a7fea 100644 --- a/makefile +++ b/makefile @@ -21,13 +21,19 @@ ISWIN := $(if $(filter linux darwin freebsd netbsd openbsd,$(KERNEL)),0,1) # profiles ifeq ($(DEBUG),1) # check whether we're debugging -CFLAGS += -Og -g -fsanitize=address,undefined -LDFLAGS += -fsanitize=address,undefined +CFLAGS += -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 -fsanitize=address -LDFLAGS += -fsanitize=address +CFLAGS += -O2 -g PROF := test +ifeq ($(ISWIN),0) +CFLAGS += -fsanitize=address +LDFLAGS += -fsanitize=address +endif else # otherwise, assume release CFLAGS += -O2 -DNDEBUG PROF := rel