From c7126c80928a70ccdb99aa845967441c619ea5d7 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Tue, 25 Aug 2015 00:29:25 +0200 Subject: begin on libmdsclient: header cherrypicking MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- mk/build.mk | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'mk') diff --git a/mk/build.mk b/mk/build.mk index 57ee222..e1e61b1 100644 --- a/mk/build.mk +++ b/mk/build.mk @@ -5,7 +5,13 @@ .PHONY: libraries -libraries: bin/libmdsserver.so +libraries: libmdsserver libmdsclient + +.PHONY: libmdsserver +libmdsserver: bin/libmdsserver.so + +.PHONY: libmdsclient +libmdsclient: bin/libmdsclient.so .PHONY: servers servers: $(foreach S,$(SERVERS),bin/$(S)) @@ -110,7 +116,7 @@ endif # Build libmdsserver. -bin/libmdsserver.so: $(foreach O,$(LIBOBJ),obj/libmdsserver/$(O).o) +bin/libmdsserver.so: $(foreach O,$(SERVEROBJ),obj/libmdsserver/$(O).o) mkdir -p $(shell dirname $@) $(CC) $(C_FLAGS) -shared -o $@ $^ @@ -118,7 +124,6 @@ obj/libmdsserver/%.o: src/libmdsserver/%.c src/libmdsserver/*.h $(SEDED) mkdir -p $(shell dirname $@) $(CC) $(C_FLAGS) -fPIC -c -o $@ $< - # sed header files. ifneq ($(LIBMDSSERVER_IS_INSTALLED),y) src/libmdsserver/config.h: src/libmdsserver/config.h.in @@ -149,3 +154,13 @@ src/libmdsserver/config.h: src/libmdsserver/config.h.in sed -i 's:@MDS_STORAGE_ROOT_DIRECTORY@:$(MDS_STORAGE_ROOT_DIRECTORY):g' $@ endif + +# Build libmdsclient. + +bin/libmdsclient.so: $(foreach O,$(CLIENTOBJ),obj/libmdsclient/$(O).o) + mkdir -p $(shell dirname $@) + $(CC) $(C_FLAGS) -shared -o $@ $^ + +obj/libmdsclient/%.o: src/libmdsclient/%.c src/libmdsclient/*.h $(SEDED) + mkdir -p $(shell dirname $@) + $(CC) $(C_FLAGS) -fPIC -c -o $@ $< -- cgit v1.2.3-70-g09d2