diff --git a/Makefile b/Makefile index 6afde4f..c8fb4f2 100644 --- a/Makefile +++ b/Makefile @@ -1,16 +1,12 @@ PROGNM = enlighten CC ?= gcc -CFLAGS ?= -O2 -fPIE -flto -fstack-protector-strong --param=ssp-buffer-size=1 -Wno-reserved-id-macro -Wall -Wextra -Wpedantic -Werror -std=gnu18 +CFLAGS ?= -O2 -fPIE -flto -fstack-protector-strong --param=ssp-buffer-size=1 -Wno-reserved-id-macro -Wall -Wextra -Wpedantic -Werror -std=gnu18 -fsanitize=undefined VER ?= $(shell (git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' || date +"v0.r%Y%m%d")) FMFLAGS = -wp -then -wp -wp-rte SOURCES = $(wildcard src/*.c) ARCH ?= $(shell uname -m) -ifneq ($(ARCH), aarch64) -CFLAGS += -fsanitize=undefined -endif - ifneq ($(CC), tcc) CFLAGS += -pie -D_FORTIFY_SOURCE=2 LDFLAGS += -Wl,-z,relro,-z,now