aboutsummaryrefslogtreecommitdiff
path: root/src/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Makefile b/src/Makefile
index 9858cdf..9fb3130 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -4,7 +4,8 @@ CC ?= gcc
WARNFLAGS ?= -Wall -Wextra
COMMONFLAGS ?= -fno-builtin -fPIC -DPIC -pthread
-OPTFLAGS ?= -O3 -DNDEBUG
+# OPTFLAGS ?= -O3 -DNDEBUG
+ OPTFLAGS ?= -O0 -g
CFLAGS ?= $(OPTFLAGS) $(WARNFLAGS) $(COMMONFLAGS)
@@ -12,12 +13,16 @@ LDFLAGS ?= -pthread -static-libgcc
.PHONY: all clean
-all: $(OBJDIR)/print_status_on_exit.so $(OBJDIR)/allocators/bumpptr_alloc.so
+all: $(OBJDIR)/print_status_on_exit.so $(OBJDIR)/allocators/bumpptr_alloc.so $(OBJDIR)/cacheline_exclusive.so
$(OBJDIR)/allocators/bumpptr_alloc.so: bumpptr_alloc.c | $(OBJDIR)/allocators
@echo "Compiling $@...";
$(CC) $(LDFLAGS) -shared $(CFLAGS) -o $@ $<
+$(OBJDIR)/cacheline_exclusive.so: cacheline_exclusive.c | $(OBJDIR)
+ @echo "Compiling $@...";
+ $(CC) $(LDFLAGS) -shared $(CFLAGS) -o $@ $<
+
$(OBJDIR)/print_status_on_exit.so: print_status_on_exit.c | $(OBJDIR)
@echo "Compiling $@...";
$(CC) $(LDFLAGS) -shared -O2 $(CFLAGS) -o $@ $<