From be160c7e5ae5445283b5b26dc6e93f11980941cc Mon Sep 17 00:00:00 2001 From: Johannes Stoelp Date: Mon, 9 Sep 2024 23:39:25 +0200 Subject: add readme and change default make target --- Makefile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index be4cf0a..71b1824 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,8 @@ -all: $(patsubst example/%.c, out/%, $(wildcard example/*.c)) -all: $(patsubst example/%.c, run/%, $(wildcard example/*.c)) +libbt.so: bt.c + $(CC) -o $@ $^ -shared -fPIC -static-libgcc -ldl $(CFLAGS) + +run: $(patsubst example/%.c, out/%, $(wildcard example/*.c)) +run: $(patsubst example/%.c, run/%, $(wildcard example/*.c)) CFLAGS := -Wall -Wextra -g CFLAGS_recurse1 := -Wno-infinite-recursion @@ -12,9 +15,6 @@ out/%: example/%.c libbt.so @mkdir -p out $(CC) -o $@ $< -rdynamic $(CFLAGS) $(CFLAGS_$*) -libbt.so: bt.c - $(CC) -o $@ $^ -shared -fPIC -static-libgcc -ldl $(CFLAGS) - clean: $(RM) -r out $(RM) libbt.so -- cgit v1.2.3