From 6c1cc0b2c854dd56dcb6238816a6ce2cb493c71c Mon Sep 17 00:00:00 2001 From: Roland Reichwein Date: Sun, 10 May 2020 18:18:37 +0200 Subject: Separated out lib --- Makefile | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 2e3f006..b9fb155 100644 --- a/Makefile +++ b/Makefile @@ -50,7 +50,8 @@ LIBS=\ -lcrypt \ -lpthread \ -lssl -lcrypto \ --ldl +-ldl \ +-lcommon #-lboost_coroutine \ #-lboost_program_options \ @@ -71,7 +72,7 @@ LIBS+= \ -lstdc++fs endif -LDFLAGS+=-pie +LDFLAGS+=-pie -Llibcommon PROGSRC=\ auth.cpp \ @@ -106,9 +107,12 @@ all: build test-$(PROJECTNAME): $(TESTSRC:.cpp=.o) $(CXX) $(LDFLAGS) $^ $(LDLIBS) $(LIBS) -o $@ -$(PROJECTNAME): $(SRC:.cpp=.o) +$(PROJECTNAME): libcommon/libcommon.a $(SRC:.cpp=.o) $(CXX) $(LDFLAGS) $^ $(LDLIBS) $(LIBS) -o $@ +libcommon/libcommon.a: + $(MAKE) -C libcommon + dep: $(TESTSRC:.cpp=.d) %.d: %.cpp @@ -157,6 +161,7 @@ clean: -rm -f plugins/*.so -find . -name '*.o' -o -name '*.d' -o -name '*.gcno' -o -name '*.gcda' | xargs rm -f for i in $(PLUGINS) ; do make -C plugins/$$i clean ; done + $(MAKE) -C libcommon clean DISTFILES= \ archive.h \ @@ -206,6 +211,9 @@ DISTFILES= \ debian/webserver.install \ debian/webserver.manpages \ debian/webserver.service \ + libcommon/Makefile \ + libcommon/mime.h \ + libcommon/mime.cpp \ plugins/cgi/cgi.h \ plugins/cgi/Makefile \ plugins/cgi/cgi.cpp \ -- cgit v1.2.3