Source: dhcpdump
Version: 1.8-2
Severity: wishlist
Tags: patch
User: [email protected]
Usertags: timestamps
X-Debbugs-Cc: [email protected]
Hi!
While working on the “reproducible builds” effort [1], we have noticed
that dhcpdump 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
diff -u dhcpdump-1.8/debian/rules dhcpdump-1.8/debian/rules
--- dhcpdump-1.8/debian/rules
+++ dhcpdump-1.8/debian/rules
@@ -24,6 +24,8 @@
version = $(shell grep "^$(source) " debian/changelog|head -1 |sed
's/.*(\(.*\)\-[^\-]*).*/\1/g')
revision = $(shell grep "^$(source) " debian/changelog|head -1 |sed
's/.*([^\-]*\-\(.*\)).*/\1/g')
+BUILD_DATE := $(shell dpkg-parsechangelog --show-field Date)
+
installbin = install -g root -o root -m 755
installdoc = install -g root -o root -m 644
@@ -74,6 +76,8 @@
#
dpkg-shlibdeps debian/tmp/usr/sbin/dhcpdump
dpkg-gencontrol -isp
+ find debian/tmp -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build debian/tmp ..
binary: binary-indep binary-arch
diff -u dhcpdump-1.8/debian/changelog dhcpdump-1.8/debian/changelog
--- dhcpdump-1.8/debian/changelog
+++ dhcpdump-1.8/debian/changelog
@@ -1,3 +1,10 @@
+dhcpdump (1.8-2.1) UNRELEASED; urgency=medium
+
+ * Non-maintainer upload.
+ * Fix mtimes before building binary packages to produce reproducible output
+
+ -- akira <[email protected]> Fri, 17 Jul 2015 17:18:14 +0200
+
dhcpdump (1.8-2) unstable; urgency=low
* Bump standards-version