about summary refs log tree commit diff stats
path: root/makefile
diff options
context:
space:
mode:
authorRen Kararou <[email protected]>2025-01-25 20:20:37 -0600
committerRen Kararou <[email protected]>2025-01-25 20:20:37 -0600
commit9ec8d6d9dc03791f6ab1e3ad108c8d705d355696 (patch)
treeeaa277a55a1bc5d4db89e3db9f4785becdcbacd3 /makefile
parenta9bddce6d690838d8bfb586da918c406dd853e93 (diff)
downloadnbtpd-canon.tar.gz
nbtpd-canon.tar.bz2
nbtpd-canon.zip
fix memory leak in main loop; fix memory leak in handlers.c HEAD canon
Diffstat (limited to 'makefile')
-rw-r--r--makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/makefile b/makefile
index c7d9caf..a4cec5a 100644
--- a/makefile
+++ b/makefile
@@ -1,6 +1,11 @@
 CC:=clang
+ifeq ($(DEBUG),1)
+CFLAGS:=-march=native -fsanitize=address -funroll-loops -Wall -Wextra -Werror -O1
+LDFLAGS:=-lpthread
+else
 CFLAGS:=-march=native -O3 -funroll-loops -Wall -Wextra -Werror
 LDFLAGS:=-flto=thin -lpthread
+endif
 
 ifeq ($(shell uname),SunOS)
 CC = gcc