Source: lilo
Version: 24.1-1
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 lilo could not be built reproducibly.

The attached patch removes extra timestamps from the build system and
ensure a stable file order when creating the source archive. Once applied,
lilo can be built reproducibly in our current experimental framework.

 [1]: https://wiki.debian.org/ReproducibleBuilds
From 77519e2f69990d0434810a24fd96bede7cb423e0 Mon Sep 17 00:00:00 2001
From: Dmitry Bogatov <kact...@gnu.org>
Date: Mon, 7 Sep 2015 18:40:58 +0300
Subject: [PATCH] Remove usage of __TIME__ and __DATE__ macros from source for
 reproducible build

---
 debian/changelog                        |  7 +++++++
 debian/patches/reproducible-build.patch | 10 ++++++++++
 debian/patches/series                   |  1 +
 3 files changed, 18 insertions(+)
 create mode 100644 debian/patches/reproducible-build.patch

diff --git a/debian/changelog b/debian/changelog
index 397cf02..2c68e8d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+lilo (1:24.1-1.0~reproducible) unstable; urgency=medium
+
+  * Remove usage of __TIME__ and __DATE__ macros from
+    source for reproducible build
+
+ -- Dmitry Bogatov <kact...@ruggedinbox.com>  Mon, 07 Sep 2015 18:38:48 +0300
+
 lilo (1:24.1-1) unstable; urgency=medium
 
   * New upstream release:
diff --git a/debian/patches/reproducible-build.patch b/debian/patches/reproducible-build.patch
new file mode 100644
index 0000000..48ffc20
--- /dev/null
+++ b/debian/patches/reproducible-build.patch
@@ -0,0 +1,10 @@
+--- a/src/lilo.c
++++ b/src/lilo.c
+@@ -839,7 +839,6 @@ fprintf(errstd,"REBOOT=\"%s\"\n", reboot
+ #include <sys/utsname.h>
+           struct utsname buf;
+ #endif
+-          printf("Compiled at %s on %s%s\n", __TIME__, __DATE__, semi);
+ #if !__MSDOS__
+           if (verbose>=2 && uname(&buf)==0) {
+             printf("Running %s kernel %s on %s\n",
diff --git a/debian/patches/series b/debian/patches/series
index a7b98cc..7c70dcf 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
+reproducible-build.patch
 01_makefile-adds.patch
 02_lilo-version-debian.patch
 03_keytab-lilo.8-debian-based.patch
-- 
I may be not subscribed. Please, keep me in carbon copy.

_______________________________________________
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds

Reply via email to