aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 5 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 70bd5e9..8e8d426 100644
--- a/Makefile
+++ b/Makefile
@@ -44,7 +44,11 @@ CFLAGS = -I. -O3 -std=c11 -fPIC
CXXFLAGS = -I. -I./examples -O3 -std=c++11 -fPIC
LDFLAGS =
-ifndef LLAMA_DEBUG
+ifdef LLAMA_DEBUG
+ CFLAGS += -O0 -g
+ CXXFLAGS += -O0 -g
+ LDFLAGS += -g
+else
CFLAGS += -DNDEBUG
CXXFLAGS += -DNDEBUG
endif