From e7f7ef7ca92048fbfc8601cb8d0eafe18783098c Mon Sep 17 00:00:00 2001 From: Jay Larson Date: Wed, 5 Apr 2017 13:47:19 -0500 Subject: [PATCH] The following changes were made to Makefile: * added BRIEF * moved to new version scheme * moved make and make install out of variables --- Makefile | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index ed9bd0d..e5beab0 100644 --- a/Makefile +++ b/Makefile @@ -11,21 +11,15 @@ DEPENDS = ARCH = x86_64 URL = http://www.gnu.org/software/cpio/ +BRIEF = cpio archive utility DESC = GNU cpio copies files into or out of a cpio or tar archive. -SNAPVER = sr0 +SNAPVER = 1 ARCHIVE := $(PWD)/SRC/$(shell ls SRC|egrep '(bz2|gz|tar|xz)$$'|tail -1) TYPE := $(shell file -ib $(ARCHIVE)|cut -d';' -f1|tr -d '\n') SRCDIR := $(shell tar -tf $(ARCHIVE)|head -1|sed 's/\/.*//') PATCHDIR := $(PWD)/SRC/patches -VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'|sed 's/^-//')$(SNAPVER) - -MAKE = make && makeinfo --html -o doc/html doc/cpio.texi && \ - makeinfo --html --no-split -o doc/cpio.html doc/cpio.texi && \ - makeinfo --plaintext -o doc/cpio.txt doc/cpio.texi -MAKEINST = make install -SNAPHACKS = rm -fv $(ROOT)/usr/share/info/dir && \ - rm -fv $(ROOT)/usr/share/man/man1/mt.1 +VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'|sed 's/^-//')-$(SNAPVER) include /usr/share/snap/Makefile.snaplinux @@ -57,8 +51,9 @@ $(SRCDIR)/config.log: $(SRCDIR)/configure --target=x86_64-snap-linux-gnu $(SRCDIR)/src/cpio: $(SRCDIR)/config.log - @cd $(SRCDIR); \ - $(MAKE) + @cd $(SRCDIR) && make && makeinfo --html -o doc/html doc/cpio.texi && \ + makeinfo --html --no-split -o doc/cpio.html doc/cpio.texi && \ + makeinfo --plaintext -o doc/cpio.txt doc/cpio.texi $(ROOT): $(SRCDIR)/src/cpio @if [ -d $(ROOT) ]; then \ @@ -67,10 +62,9 @@ $(ROOT): $(SRCDIR)/src/cpio mkdir -v $(ROOT); \ fi - @cd $(SRCDIR); \ - $(MAKEINST) DESTDIR=$(ROOT) - - @$(SNAPHACKS) + @cd $(SRCDIR) && make install DESTDIR=$(ROOT) && \ + rm -fv $(ROOT)/usr/share/info/dir && \ + rm -fv $(ROOT)/usr/share/man/man1/mt.1 test: $(ROOT) @cd $(SRCDIR); \