From ea59a3554ab89220219398f387ff4746771e4839 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Wed, 23 Apr 2014 06:34:51 +0200 Subject: m make MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index bfe7142..9840226 100644 --- a/Makefile +++ b/Makefile @@ -59,6 +59,10 @@ C_FLAGS = $(OPTIMISE) $(WARN) -std=$(STD) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) \ -D_GNU_SOURCE -pthread +# Object files for the libary +LIBOBJ = linked-list hash-table + + # Build rules. .PHONY: all @@ -74,7 +78,7 @@ obj/%.o: src/%.c src/%.h src/config.h gcc $(C_FLAGS) -Isrc -c -o $@ $< -bin/libmdsserver.so: obj/libmdsserver/linked-list.o obj/libmdsserver/hash-table.o +bin/libmdsserver.so: $(foreach O,$(LIBOBJ),obj/libmdsserver/$(O).o) mkdir -p $(shell dirname $@) gcc $(C_FLAGS) -shared -o $@ $^ -- cgit v1.2.3-70-g09d2