Package: dipy
Version: 0.7.1-2
Severity: wishlist
Tags: patch
User: [email protected]
Usertags: timestamps

Hi!

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

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

 [1]: https://wiki.debian.org/ReproducibleBuilds
diff -urNp dipy-0.7.1.old/debian/rules dipy-0.7.1/debian/rules
--- dipy-0.7.1.old/debian/rules	2014-08-13 11:18:54.000000000 -0300
+++ dipy-0.7.1/debian/rules	2015-06-24 00:00:43.428334134 -0300
@@ -22,6 +22,10 @@ upver = $(shell echo $(debver) | cut -d
 
 MIN_CYTHONVER = 0.17.3
 
+LAST_CHANGE = $(shell dpkg-parsechangelog -S Date)
+BUILD_DATE  = $(shell LC_ALL=C date -u "+%B %d, %Y" -d "$(LAST_CHANGE)")
+SPHINXOPTS := -D today=\"$(BUILD_DATE)\"
+
 %:
 	dh --buildsystem=python_distutils $@
 
@@ -74,7 +78,7 @@ ifeq (,$(filter nodoc,$(DEB_BUILD_OPTION
 	cp -rp doc-examples/doc/examples_built/* doc/examples_built/
 	export PYTHONPATH=$$(/bin/ls -d $(INSTALL_PATH)/usr/lib/$(PYTHON)/*-packages) \
 		   MPLCONFIGDIR=$(CURDIR)/build HOME=$(CURDIR)/build; \
-	cd doc; $(MAKE) html-after-examples
+	cd doc; $(MAKE) html-after-examples SPHINXOPTS="$(SPHINXOPTS)"
 	-rm doc/_build/html/_static/jquery.js
 	-rm -r doc/_build/html/_sources
 	: # objects inventory is of no use for the package

Reply via email to