[spatialite-tools] 01/03: Set the date embedded in man pages to the changelog date for reproducible builds.

Sebastiaan Couwenberg sebastic at moszumanska.debian.org
Thu Apr 23 21:46:21 UTC 2015


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

sebastic pushed a commit to branch experimental
in repository spatialite-tools.

commit d3da6ae5cc63212afeda39ed5e372be8b3ee69df
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date:   Thu Apr 23 23:40:06 2015 +0200

    Set the date embedded in man pages to the changelog date for reproducible builds.
---
 debian/changelog | 2 ++
 debian/rules     | 8 ++++----
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index bd1465b..3bb80b0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,8 @@ spatialite-tools (4.2.1~rc1-2) UNRELEASED; urgency=medium
 
   * Add upstream metadata.
   * Update Vcs-Browser URL to use cgit instead of gitweb.
+  * Set the date embedded in man pages to the changelog date for
+    reproducible builds.
 
  -- Bas Couwenberg <sebastic at xs4all.nl>  Sat, 29 Nov 2014 00:07:26 +0100
 
diff --git a/debian/rules b/debian/rules
index c276dfe..e1b3d4a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -11,6 +11,8 @@ FULL_VERSION := $(shell dpkg-parsechangelog | grep ^Version | cut -d' ' -f2 | cu
 VERSION := $(shell echo $(FULL_VERSION) | sed -e "s/~beta[[:digit:]]\+/-BETA/")
 LC_VERSION := $(shell echo $(VERSION) | tr A-Z a-z)
 
+BUILD_DATE=$(shell dpkg-parsechangelog | sed -ne 's/^Date: //p' | LC_ALL=C date -u "+%d %B %Y" -f -)
+
 MANPAGES := $(wildcard debian/man/*.*.xml)
 
 DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
@@ -23,9 +25,7 @@ versions:
 	@echo "Spatialite version: $(LC_VERSION)"
 
 override_dh_clean:
-	dh_clean
-
-	-$(RM) -f $(CURDIR)/debian/man/*.1
+	dh_clean debian/man/*.1
 
 override_dh_auto_configure:
 	dh_auto_configure -- $(shell dpkg-buildflags --export=configure)
@@ -33,7 +33,7 @@ override_dh_auto_configure:
 override_dh_auto_build:
 	# Create man page from DocBook XML
 	for x in $(MANPAGES) ; do \
-	    docbook2x-man $$x ; \
+	    docbook2x-man --string-param header-3="$(BUILD_DATE)" $$x ; \
 	    mv `basename $$x | sed 's/.xml$$//'` `dirname $$x` ; \
 	done
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/spatialite-tools.git



More information about the Pkg-grass-devel mailing list