[xml/sgml-commit] [linuxdoc-tools] 03/04: Makefile.maint: New tarball+sums target to calculate hashsums after creating the tarball.

Agustín Martín Domingo agmartin at moszumanska.debian.org
Tue Oct 20 11:44:21 UTC 2015


This is an automated email from the git hooks/post-receive script.

agmartin pushed a commit to branch upstream
in repository linuxdoc-tools.

commit e4422490b73009aed3a30d527ec520ff33a9cf40
Author: Agustin Martin Domingo <agmartin at debian.org>
Date:   Tue Oct 20 13:05:55 2015 +0200

    Makefile.maint: New tarball+sums target to calculate hashsums after creating the tarball.
    
    Signed-off-by: Agustin Martin Domingo <agmartin at debian.org>
---
 Makefile.maint | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/Makefile.maint b/Makefile.maint
index f52860c..cd42c90 100644
--- a/Makefile.maint
+++ b/Makefile.maint
@@ -30,15 +30,25 @@ COPYING: Makefile.maint linuxdoc-tools.copyright sgmls-1.1/LICENSE iso-entities/
 
 tarball: VERSION = $(shell cat VERSION)
 tarball: GIT_STATUS = $(shell git status --porcelain)
+tarball: TARBALL = ../linuxdoc-tools-$(VERSION).tar.gz
 tarball:
 	$(if $(wildcard ../linuxdoc-tools-$(VERSION).tar.gz), \
 		$(error "../linuxdoc-tools-$(VERSION).tar.gz tarball already exists. Skipping"))
 	@if test -z "$(GIT_STATUS)"; then \
 	git archive --format tar.gz \
 		    --prefix linuxdoc-tools-$(VERSION)/ \
-		    --output ../linuxdoc-tools-$(VERSION).tar.gz HEAD; \
+		    --output $(TARBALL) HEAD; \
         else echo "$(GIT_STATUS)"; fi
 
+tarball+sums: VERSION = $(shell cat VERSION)
+tarball+sums: TARBALL = linuxdoc-tools-$(VERSION).tar.gz
+tarball+sums: tarball
+	( cd .. && ( \
+	[ -z "`which md5sum`" ] || md5sum $(TARBALL); \
+	[ -z "`which sha1sum`" ] || sha1sum $(TARBALL); \
+	[ -z "`which sha256sum`" ] || sha256sum $(TARBALL); \
+	[ -z "`which sha512sum`" ] || sha512sum $(TARBALL); ))
+
 # Local Variables:
 # mode: makefile
 # End:

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-xml-sgml/linuxdoc-tools.git



More information about the debian-xml-sgml-commit mailing list