Bug#998312: ibus-input-pad: please make the build reproducible

Chris Lamb lamby at debian.org
Tue Nov 2 09:34:15 GMT 2021


Source: ibus-input-pad
Version: 1.4.99.20140916-1
Severity: wishlist
Tags: patch
User: reproducible-builds at lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-Cc: reproducible-bugs at lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0] we noticed that
ibus-input-pad could not be built reproducibly.

This is because various files include the current build timestamp.
A patch is attached that uses SOURCE_DATE_EPOCH for these dates if
that variable is available.

 [0] https://reproducible-builds.org/


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby at debian.org / chris-lamb.co.uk
       `-
-------------- next part --------------
--- a/debian/patches/reproducible-build.patch	1970-01-01 01:00:00.000000000 +0100
--- b/debian/patches/reproducible-build.patch	2021-11-02 09:24:23.892134087 +0000
@@ -0,0 +1,24 @@
+Description: Make the build reproducible
+Author: Chris Lamb <lamby at debian.org>
+Last-Update: 2021-11-02
+
+--- ibus-input-pad-1.4.99.20140916.orig/configure.ac
++++ ibus-input-pad-1.4.99.20140916/configure.ac
+@@ -26,7 +26,7 @@ m4_define([ibus_minor_version], [4])
+ m4_define([ibus_micro_version], [99])
+ m4_define([pad_abi_current], [1])
+ m4_define(ibus_maybe_datestamp,
+-    m4_esyscmd([if test x]ibus_released[ != x1; then date +.%Y%m%d | tr -d '\n\r'; fi]))
++    m4_esyscmd([if test x]ibus_released[ != x1; then date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" +.%Y%m%d | tr -d '\n\r'; fi]))
+ 
+ m4_define([ibus_version],
+     ibus_major_version.ibus_minor_version.ibus_micro_version[]ibus_maybe_datestamp)
+@@ -56,7 +56,7 @@ IT_PROG_INTLTOOL([0.35.0])
+ 
+ dnl - For dislpay Date
+ m4_define(ibus_datedisplay,
+-    m4_esyscmd(date '+%a %b %d %Y' | tr -d '\n\r'))
++    m4_esyscmd(date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" '+%a %b %d %Y' | tr -d '\n\r'))
+ DATE_DISPLAY="ibus_datedisplay"
+ AC_SUBST(DATE_DISPLAY)
+ 
--- a/debian/patches/series	1970-01-01 01:00:00.000000000 +0100
--- b/debian/patches/series	2021-11-02 09:24:23.060130720 +0000
@@ -0,0 +1 @@
+reproducible-build.patch


More information about the Reproducible-bugs mailing list