aboutsummaryrefslogtreecommitdiff
path: root/src/Makefile
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fl.fischer@fau.de>2020-05-06 16:56:32 +0200
committerFlorian Fischer <florian.fl.fischer@fau.de>2020-06-02 11:18:47 +0200
commit8174a918ea3b7cb216bf7ea98cfdc10661b5c37d (patch)
tree0747ec3ccb9f8d7eeccfac35977fc17855ca3bbb /src/Makefile
parent8f52e8fc02dd235582f5961941bcd564e9a681cd (diff)
downloadallocbench-8174a918ea3b7cb216bf7ea98cfdc10661b5c37d.tar.gz
allocbench-8174a918ea3b7cb216bf7ea98cfdc10661b5c37d.zip
make the whole project more python idiomatic
* rename src directory to allocbench * make global variable names UPPERCASE * format a lot of code using yapf * use lowercase ld_preload and ld_library_path as Allocator members * name expected Errors 'err' and don't raise a new Exception * disable some pylint messages
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile45
1 files changed, 0 insertions, 45 deletions
diff --git a/src/Makefile b/src/Makefile
deleted file mode 100644
index caceb19..0000000
--- a/src/Makefile
+++ /dev/null
@@ -1,45 +0,0 @@
-OBJDIR ?= obj
-
-CC ?= gcc
-
-WARNFLAGS ?= -Wall -Wextra
-COMMONFLAGS ?= -fno-builtin -fPIC -DPIC -pthread
-OPTFLAGS ?= -O0 -g
-
-CFLAGS ?= $(OPTFLAGS) $(WARNFLAGS) $(COMMONFLAGS)
-
-LDFLAGS ?= -pthread -static-libgcc
-
-MEMSIZE_KB=$(shell free -t | tail -1 | tr -s ' ' | cut -d ' ' -f 2)
-MEMSIZE="$(MEMSIZE_KB) * 1024l"
-
-TOOLS = print_status_on_exit.so exec sig_handlers.so
-ALLOCS = bumpptr_alloc.so align_to_cl.so
-TARGETS = $(addprefix $(OBJDIR)/allocators/,$(ALLOCS)) $(addprefix $(OBJDIR)/,$(TOOLS))
-
-.PHONY: all clean
-
-all: $(TARGETS)
-
-$(OBJDIR)/allocators/bumpptr_alloc.so: bumpptr_alloc.c malloc.c Makefile
- @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi
- $(CC) $(LDFLAGS) -shared -DMEMSIZE=$(MEMSIZE) $(CFLAGS) -o $@ bumpptr_alloc.c malloc.c
-
-$(OBJDIR)/allocators/align_to_cl.so: align_to_cl.c Makefile
- @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi
- $(CC) $(LDFLAGS) -shared $(CFLAGS) -o $@ $< -ldl
-
-$(OBJDIR)/print_status_on_exit.so: print_status_on_exit.c Makefile
- @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi
- $(CC) $(LDFLAGS) -shared $(CFLAGS) -o $@ $<
-
-$(OBJDIR)/sig_handlers.so: sig_handlers.c Makefile
- @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi
- $(CC) $(LDFLAGS) -shared $(CFLAGS) -o $@ $<
-
-$(OBJDIR)/exec: exec.c Makefile
- @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi
- $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
-
-clean:
- rm -rf $(OBJDIR)