Source: mapserver
Version: 6.4.1-5
Severity: wishlist
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-CC: reproducible-builds@lists.alioth.debian.org

Hi!

While working on Debian's “reproducible builds” effort [1], we have
noticed that mapserver doesn't build reproducibly.
During build the current date is embedded into the manpages.

The attached patch uses the date from the latest changelog entry
inside the manpages.

Regards,
 Reiner

[1]: https://wiki.debian.org/ReproducibleBuilds


diff --git a/debian/rules b/debian/rules
index 604b749..c30657e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -26,6 +26,7 @@ PHP5API=$(shell php-config5 --phpapi)
 MANPAGES:=$(wildcard debian/man/*.*.xml)
 
 MS_VERSION=$(shell dpkg-parsechangelog | sed -ne 's/^Version: \(.*\)-.*/\1/p')
+BUILD_DATE=$(shell dpkg-parsechangelog | sed -ne 's/^Date: //p' | LC_ALL=C date -u "+%d %B %Y" -f -)
 
 CMAKE_OPTS:= \
 		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
@@ -106,7 +107,7 @@ override_dh_auto_configure:
 override_dh_auto_build:
 	# Create man pages 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
 

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds

Reply via email to