From: ewt Date: Tue, 2 Apr 1996 03:36:30 +0000 (+0000) Subject: creates tagtable.c now X-Git-Tag: rpm-4.4-release~5218 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4f94ee363c4ae295c4fcbe1fd2d10a5754055462;p=platform%2Fupstream%2Frpm.git creates tagtable.c now CVS patchset: 517 CVS date: 1996/04/02 03:36:30 --- diff --git a/lib/Makefile.in b/lib/Makefile.in index 566f52f..aee7ee9 100644 --- a/lib/Makefile.in +++ b/lib/Makefile.in @@ -1,10 +1,13 @@ LIBOBJECTS = header.o oldrpmdb.o misc.o messages.o rpmerr.o falloc.o \ var.o md5.o md5sum.o dbindex.o rpmrc.o \ rpmdb.o stringbuf.o rpmlead.o package.o uninstall.o \ - oldheader.o install.o signature.o verify.o + oldheader.o install.o signature.o verify.o +SOURCES = $(subst .o,.c,$(LIBOBJECTS)) +TAGTABLE = tagtable.o LIBRPM = librpm.a LOADLIBES = -lrpm -lgdbm -ldb $(LIBEFENCE) PROGS = +AR = ar # ----------------------------------------------------------------------- @@ -20,10 +23,18 @@ allprogs: $(LIBRPM) $(PROGS) $(PROGS): $(LIBRPM) -$(LIBRPM): $(LIBOBJECTS) - $(AR) $@ $(LIBOBJECTS) +$(LIBRPM): $(LIBRPM)($(LIBOBJECTS) $(TAGTABLE)) $(RANLIB) $@ +tagtable.c: rpmlib.h Makefile + echo '#include "rpmlib.h"' > tagtable.c + echo '' >> tagtable.c + echo 'const struct rpmTagTableEntry rpmTagTable[] = {' >> tagtable.c + perl -ne '/(RPMTAG_[A-Z0-9]*)[ \t]+([0-9]*)/ && do { printf("\t{ \"$$1\", $$2 },\n"); }' < rpmlib.h >> tagtable.c + echo '};' >> tagtable.c + echo '' >> tagtable.c + echo 'const int rpmTagTableSize = sizeof(rpmTagTable) / sizeof(struct rpmTagTableEntry);' >> tagtable.c + install: install -m 755 -o 0 -g 0 -d $(INCDIR) install -m 755 -o 0 -g 0 -d $(LIBDIR) @@ -41,7 +52,7 @@ squeaky: clean rm -f depend depend: - $(CPP) $(CFLAGS) -M *.c > .depend + $(CPP) $(CFLAGS) -M $(SOURCES) > .depend ifeq (.depend,$(wildcard .depend)) include .depend