X-Git-Url: http://git.vrable.net/?a=blobdiff_plain;f=Makefile;h=854be806ad1f904777b92468808b2c53d1d0d4f6;hb=ed9f6041c4c8c653e44a8edeeaa846e5db01587b;hp=8fc6f05700ed4d54587a63df09628a7b21db68e2;hpb=b57ca1c9e3f6fd1e4ea796e82e9863ffab0cb76e;p=cumulus.git diff --git a/Makefile b/Makefile index 8fc6f05..854be80 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,26 @@ -CXXFLAGS=-O -Wall -D_FILE_OFFSET_BITS=64 +PACKAGES=sqlite3 uuid +DEBUG=-g #-pg +CXXFLAGS=-O -Wall -D_FILE_OFFSET_BITS=64 $(DEBUG) \ + `pkg-config --cflags $(PACKAGES)` -DLBS_VERSION=`cat version` +LDFLAGS=$(DEBUG) `pkg-config --libs $(PACKAGES)` -OBJS=scandir.o +SRCS=localdb.cc ref.cc scandir.cc sha1.cc statcache.cc store.cc util.cc +OBJS=$(SRCS:.cc=.o) -scandir : $(OBJS) +lbs : $(OBJS) $(CXX) $(LDFLAGS) -o $@ $^ + +version : NEWS + (git-describe || (head -n1 NEWS | cut -d" " -f1)) >version +$(OBJS) : version + +clean : + rm -f $(OBJS) lbs version + +dep : + touch Makefile.dep + makedepend -fMakefile.dep $(SRCS) + +.PHONY : clean dep + +-include *.dep