Source: nitpic Version: 0.1-15 Severity: wishlist Tags: patch User: reproducible-builds@lists.alioth.debian.org Usertags: timestamps X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org Hi! While working on the “reproducible builds” effort [1], we have noticed that nitpic 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. Please also consider this other bug from the reproducible builds team: https://bugs.debian.org/777492 Cheers, akira [1]: https://wiki.debian.org/ReproducibleBuilds
diff -u nitpic-0.1/debian/changelog nitpic-0.1/debian/changelog --- nitpic-0.1/debian/changelog +++ nitpic-0.1/debian/changelog @@ -1,3 +1,10 @@ +nitpic (0.1-16) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix mtimes before building binary packages to produce reproducible output + + -- akira <marivalenm@gmail.com> Fri, 24 Jul 2015 15:12:07 +0200 + nitpic (0.1-15) unstable; urgency=medium * QA upload. diff -u nitpic-0.1/debian/rules nitpic-0.1/debian/rules --- nitpic-0.1/debian/rules +++ nitpic-0.1/debian/rules @@ -9,6 +9,8 @@ Makefile: Imakefile xmkmf +export SOURCE_DATE_EPOCH = $(shell date -d "$$(dpkg-parsechangelog --count 1 -SDate)" +%s) + build: build-arch build-indep: build-arch: checkdir Makefile @@ -61,6 +63,8 @@ endif dpkg-shlibdeps $(d)/usr/bin/* dpkg-gencontrol -isp -p$(package) -P$(d) + find $(d) -newermt "@$$SOURCE_DATE_EPOCH" -print0 | \ + xargs -0r touch --no-dereference --date="@$$SOURCE_DATE_EPOCH" dpkg --build $(d) .. binary: binary-indep binary-arch
Attachment:
signature.asc
Description: OpenPGP digital signature