summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile7
1 files changed, 6 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 7ab10e1..cca0169 100644
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,7 @@ OUTDIR = build
BENCH_OUT = $(OUTDIR)/bench
LIB = libtinyff.a
-ALL_CFLAGS = -Wall -Wextra -Werror -std=c11 -Iinclude -Ibench
+ALL_CFLAGS = -Wall -Wextra -Werror -std=c11 -Iinclude
DEBUG_FLAGS = -g -O0 -fno-omit-frame-pointer
RELEASE_FLAGS = -O2
@@ -19,6 +19,11 @@ ALL_CFLAGS += -DUSE_HOSTED -Iinclude/bridges
SRC += $(shell find src/bridges -name "*.c")
endif
+ifeq ($(USE_BENCH),1)
+ALL_CFLAGS += -DUSE_BENCH -Ibench
+SRC += $(shell find bench/src -name "*.c")
+endif
+
OBJ = $(patsubst %.c,$(OUTDIR)/%.o,$(SRC))
all: release