Source: echoping
Version: 6.0.2-9
Severity: wishlist
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0], I noticed
that echoping could not be built reproducibly.

Patch attached.

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


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
--- a/debian/patches/006_reproducible-build.diff        1970-01-01 
01:00:00.000000000 +0100
--- b/debian/patches/006_reproducible-build.diff        2016-08-19 
23:25:14.950925873 +0100
@@ -0,0 +1,40 @@
+Description: Make the build reproducible
+Author: Chris Lamb <la...@debian.org>
+Last-Update: 2016-08-19
+
+--- echoping-6.0.2.orig/configure
++++ echoping-6.0.2/configure
+@@ -23320,8 +23320,13 @@ echo "${ECHO_T}disabled" >&6; }
+ fi
+ 
+ 
+-compil_date=`date +%Y-%m-%d`
+-hostname=$ac_hostname
++if test "x$SOURCE_DATE_EPOCH" = "x"; then
++      compil_date=`date +%Y-%m-%d`
++      hostname=$ac_hostname
++else
++      compil_date=`date --utc --date="@$SOURCE_DATE_EPOCH" +%Y-%m-%d`
++      hostname=generic
++fi
+ 
+ 
+ 
+--- echoping-6.0.2.orig/configure.ac
++++ echoping-6.0.2/configure.ac
+@@ -334,8 +334,13 @@ DISPLAY_SETTING(LIBIDN)
+ DISPLAY_SETTING(TOS)
+ DISPLAY_SETTING(PRIORITY)
+ 
+-compil_date=`date +%Y-%m-%d`
+-hostname=$ac_hostname
++if test "x$SOURCE_DATE_EPOCH" = "x"; then
++      compil_date=`date +%Y-%m-%d`
++      hostname=$ac_hostname
++else
++      compil_date=`date --utc --date="@$SOURCE_DATE_EPOCH" +%Y-%m-%d`
++      hostname=generic
++fi
+ AC_SUBST(hostname)
+ AC_SUBST(compil_options)
+ AC_SUBST(compil_date)
--- a/debian/patches/series     2016-08-19 23:13:25.240754904 +0100
--- b/debian/patches/series     2016-08-19 23:16:12.530211168 +0100
@@ -3,3 +3,4 @@
 003-fix-for-https-creashes.diff
 002-FTBFS_against_gnutls26_greater_the_2.7.x_fix.diff
 001-manpage_fixes.diff
+006_reproducible-build.diff
_______________________________________________
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