[Reproducible-builds] Bug#793003: daemontools: please make the build reproducible
Maria Valentina Marin
marivalenm at gmail.com
Mon Jul 20 11:54:32 UTC 2015
Source: daemontools
Version: 1:0.76-6
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 daemontools 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 -u daemontools-0.76/debian/changelog daemontools-0.76/debian/changelog
--- daemontools-0.76/debian/changelog
+++ daemontools-0.76/debian/changelog
@@ -1,3 +1,10 @@
+daemontools (1:0.76-6.1) 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 16:42:42 +0200
+
daemontools (1:0.76-6) unstable; urgency=medium
* workaround #767933 by copying from sysvinit-2.88dsf:
diff -u daemontools-0.76/debian/rules daemontools-0.76/debian/rules
--- daemontools-0.76/debian/rules
+++ daemontools-0.76/debian/rules
@@ -7,6 +7,8 @@
DIR =$(shell pwd)/debian/daemontools
+BUILD_DATE := $(shell dpkg-parsechangelog --show-field Date)
+
patch: deb-checkdir patch-stamp
patch-stamp:
for i in `ls -1 debian/diff/*.diff || :`; do \
@@ -94,9 +96,13 @@
binary-arch: install-arch daemontools.deb
dpkg-shlibdeps '$(DIR)'/usr/bin/*
dpkg-gencontrol -isp -pdaemontools -P'$(DIR)'
+ find '$(DIR)' -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg -b '$(DIR)' ..
binary-indep: install-indep daemontools-run.deb
dpkg-gencontrol -isp -pdaemontools-run -P'$(DIR)'-run
+ find '$(DIR)'-run -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg -b '$(DIR)'-run ..
binary: binary-indep binary-arch
More information about the Reproducible-builds
mailing list