Source: freecdb Version: 0.75 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 freecdb 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 -Nru freecdb-0.75/debian/changelog freecdb-0.75+nmu1/debian/changelog --- freecdb-0.75/debian/changelog 2006-01-13 22:12:00.000000000 +0100 +++ freecdb-0.75+nmu1/debian/changelog 2015-07-19 13:45:25.000000000 +0200 @@ -1,3 +1,10 @@ +freecdb (0.75+nmu1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix mtimes before building binary packages to produce reproducible output + + -- akira <marival...@gmail.com> Sun, 19 Jul 2015 13:45:01 +0200 + freecdb (0.75) unstable; urgency=low * take over upstream (closes: #272127). diff -Nru freecdb-0.75/debian/rules freecdb-0.75+nmu1/debian/rules --- freecdb-0.75/debian/rules 2006-01-13 22:12:00.000000000 +0100 +++ freecdb-0.75+nmu1/debian/rules 2015-07-19 13:44:58.000000000 +0200 @@ -12,6 +12,8 @@ DIR =$(shell pwd)/debian/freecdb +BUILD_DATE := $(shell dpkg-parsechangelog --show-field Date) + build: deb-checkdir build-stamp build-stamp: $(MAKE) CC='$(CC)' @@ -40,6 +42,8 @@ binary-arch: install freecdb.deb test '$(CC)' != 'gcc' || dpkg-shlibdeps '$(DIR)'/usr/bin/* dpkg-gencontrol -isp -pfreecdb -P'$(DIR)' + find '$(DIR)' -newermt '$(BUILD_DATE)' -print0 | \ + xargs -0r touch --no-dereference --date='$(BUILD_DATE)' dpkg -b '$(DIR)' .. binary: binary-indep binary-arch
_______________________________________________ Reproducible-builds mailing list Reproducible-builds@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds