Source: kexec-tools Version: 2.0.7-5.1 Severity: wishlist Tags: patch User: reproducible-builds@lists.alioth.debian.org Usertags: timestamps
Hi! While working on the “reproducible builds” effort [1], we have noticed that kexec-tools could not be built reproducibly. The attached patch set the build date to the date of the latest debian/changelog entry. Once applied, kexec-tools can be built reproducibly in our current experimental framework. [1]: https://wiki.debian.org/ReproducibleBuilds -- Lunar .''`. lu...@debian.org : :Ⓐ : # apt-get install anarchism `. `'` `-
diff -Nru kexec-tools-2.0.7/debian/changelog kexec-tools-2.0.7/debian/changelog --- kexec-tools-2.0.7/debian/changelog 2015-04-22 12:06:28.000000000 +0200 +++ kexec-tools-2.0.7/debian/changelog 2015-04-24 13:47:11.000000000 +0200 @@ -1,3 +1,11 @@ +kexec-tools (1:2.0.7-5.1.0~reproducible1) UNRELEASED; urgency=low + + * Make the package build reproducibly: + - Add a patch to enable build date to be externally set. + - Set the build date to the latest debian/changelog entry. + + -- Jérémy Bobbio <lu...@debian.org> Fri, 24 Apr 2015 13:46:29 +0200 + kexec-tools (1:2.0.7-5.1) unstable; urgency=medium * Non-maintainer upload. diff -Nru kexec-tools-2.0.7/debian/patches/allow-external-build-date.patch kexec-tools-2.0.7/debian/patches/allow-external-build-date.patch --- kexec-tools-2.0.7/debian/patches/allow-external-build-date.patch 1970-01-01 01:00:00.000000000 +0100 +++ kexec-tools-2.0.7/debian/patches/allow-external-build-date.patch 2015-04-24 13:48:19.000000000 +0200 @@ -0,0 +1,20 @@ +Description: Allow build date to be set externally + In order to allow the package to be built reproducibly, we can now + set the build date through the BUILD_DATE environment variable when + running ./configure. +Author: Jérémy Bobbio <lu...@debian.org> + +--- kexec-tools-2.0.7.orig/configure.ac ++++ kexec-tools-2.0.7/configure.ac +@@ -9,7 +9,10 @@ AC_CONFIG_AUX_DIR(./config) + AC_CONFIG_HEADERS([include/config.h]) + AC_LANG(C) + +-AC_DEFINE_UNQUOTED(PACKAGE_DATE, "`date '+%d %B %Y'`", ++if test "x$BUILD_DATE" = x; then ++ BUILD_DATE=`date '+%d %B %Y'` ++fi ++AC_DEFINE_UNQUOTED(PACKAGE_DATE, "$BUILD_DATE", + [Define to the release date of this package]) + + diff -Nru kexec-tools-2.0.7/debian/patches/series kexec-tools-2.0.7/debian/patches/series --- kexec-tools-2.0.7/debian/patches/series 2015-04-22 12:07:00.000000000 +0200 +++ kexec-tools-2.0.7/debian/patches/series 2015-04-24 13:47:32.000000000 +0200 @@ -7,3 +7,4 @@ const_string_warning.patch powerpcspe_support.patch fix-callback-functions-given-to-kexec_iomem_for_each_line.patch +allow-external-build-date.patch diff -Nru kexec-tools-2.0.7/debian/rules kexec-tools-2.0.7/debian/rules --- kexec-tools-2.0.7/debian/rules 2014-10-10 18:29:32.000000000 +0200 +++ kexec-tools-2.0.7/debian/rules 2015-04-24 13:45:58.000000000 +0200 @@ -8,6 +8,8 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +BUILD_DATE = $(shell dpkg-parsechangelog -S Date | date -u +'%d %B %Y' -f -) +export BUILD_DATE ifneq (,$(filter parallel=%,$(subst $(COMMA), ,$(DEB_BUILD_OPTIONS)))) NJOBS := -j $(subst parallel=,,$(filter parallel=%,$(subst $(COMMA), ,$(DEB_BUILD_OPTIONS))))
signature.asc
Description: Digital signature
_______________________________________________ Reproducible-builds mailing list Reproducible-builds@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds