From e9b7a6ef8fc575e0ee4f55ae16169d1917be9dea Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 24 Aug 2023 00:58:23 +0200 Subject: Initial commit --- Makefile | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..100896b --- /dev/null +++ b/Makefile @@ -0,0 +1,21 @@ +.PHONY: all clean + +OBJS = libtwn3.so libtwn3.debug.so twn3_test +CFLAGS = -g -Wall -Wpedantic + +%.so: CFLAGS += -shared -fPIC +%.debug.so: CFLAGS += -DDEBUG + +%.so :: %.c %.h + $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) $(LDLIBS) + +%.debug.so :: %.c %.h + $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) $(LDLIBS) + +twn3_test: LDLIBS = -ltwn3.debug +twn3_test: LDFLAGS = -L. -Wl,-rpath . + +all: $(OBJS) + +clean: + $(RM) $(OBJS) -- cgit v1.2.3