Package: python-repoze.tm2
Version: 2.0-1
Severity: wishlist
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: timestamps

Hi!

While working on the "reproducible builds" effort [1], we have noticed
that python-repoze.tm2 could not be built reproducibly.

The attached patch removes extra timestamps from the build system.
Once applied, python-repoze.tm2 can be built reproducibly in our current
experimental framework.

 [1]: https://wiki.debian.org/ReproducibleBuilds
diff -ruNp python-repoze.tm2-2.0.old/debian/rules python-repoze.tm2-2.0/debian/rules
--- python-repoze.tm2-2.0.old/debian/rules	2014-09-28 12:19:16.000000000 -0300
+++ python-repoze.tm2-2.0/debian/rules	2015-06-11 23:01:23.412037493 -0300
@@ -2,10 +2,13 @@
 
 #DH_VERBOSE=1
 PYBUILD_NAME=python-repoze.tm2
+LAST_CHANGE = $(shell dpkg-parsechangelog -S Date)
+BUILD_DATE  = $(shell LC_ALL=C date -u "+%B %d, %Y" -d "$(LAST_CHANGE)")
+SPHINXOPTS := -D html_last_updated_fmt="$(BUILD_DATE)"
 
 override_dh_sphinxdoc:
 ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS)))
-	sphinx-build -b html docs $(CURDIR)/debian/python-repoze.tm2-doc/usr/share/doc/python-repoze.tm2-doc/html
+	sphinx-build $(SPHINXOPTS) -b html docs $(CURDIR)/debian/python-repoze.tm2-doc/usr/share/doc/python-repoze.tm2-doc/html
 	dh_sphinxdoc -O--buildsystem=pybuild
 endif
 

Reply via email to