[Reproducible-builds] Bug#792955: dput: please make the build reproducible
Maria Valentina Marin
marivalenm at gmail.com
Mon Jul 20 11:13:39 UTC 2015
Source: dput
Version: 0.9.6.4
Severity: wishlist
Tags: patch
User: reproducible-builds at lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-Cc: reproducible-builds at lists.alioth.debian.org
Hi!
While working on the “reproducible builds” effort [1], we have noticed
that dput could not be built reproducibly.
The attached patch sets the mtimes of all files which are modified
during the built to the date of the last changelog entry in order to
produce files with reproducible metadata.
Cheers,
akira
[1]: https://wiki.debian.org/ReproducibleBuilds
-------------- next part --------------
diff -Nru dput-0.9.6.4/debian/changelog dput-0.9.6.4+nmu1/debian/changelog
--- dput-0.9.6.4/debian/changelog 2013-07-19 13:08:40.000000000 +0200
+++ dput-0.9.6.4+nmu1/debian/changelog 2015-07-17 17:40:02.000000000 +0200
@@ -1,3 +1,10 @@
+dput (0.9.6.4+nmu1) UNRELEASED; urgency=medium
+
+ * Non-maintainer upload.
+ * Fix mtimes before building binary packages to produce reproducible output
+
+ -- akira <marivalenm at gmail.com> Fri, 17 Jul 2015 17:39:50 +0200
+
dput (0.9.6.4) unstable; urgency=low
[ Salvatore Bonaccorso ]
diff -Nru dput-0.9.6.4/debian/rules dput-0.9.6.4+nmu1/debian/rules
--- dput-0.9.6.4/debian/rules 2013-07-19 12:48:57.000000000 +0200
+++ dput-0.9.6.4+nmu1/debian/rules 2015-07-17 17:39:47.000000000 +0200
@@ -3,6 +3,8 @@
PACKAGE := dput
TMPDIR := debian/tmp
+BUILD_DATE := $(shell dpkg-parsechangelog --show-field Date)
+
build: build-arch build-indep
build-arch: build-stamp
build-indep: build-stamp
@@ -61,6 +63,8 @@
install --mode=0755 debian/prerm $(TMPDIR)/DEBIAN
install --mode=0755 debian/postinst $(TMPDIR)/DEBIAN
dpkg-gencontrol -isp
+ find debian/tmp -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(TMPDIR) ..
# Build architecture-dependent files here.
More information about the Reproducible-builds
mailing list