Hi,

> buzztrax: please make the build reproducible

Updated patch attached; the previous one didn't correctly fallback to the 
lowest-common-denominator shell syntax required for portable autotools.


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
diff --git a/configure.ac b/configure.ac
index 1bdec63..5479c16 100644
--- a/configure.ac
+++ b/configure.ac
@@ -49,8 +49,14 @@ AC_DEFINE_UNQUOTED(GST_MAJORMINOR, "$GST_MAJORMINOR", 
[gstreamer series])
 AC_SUBST(GST_MAJORMINOR)
 
 dnl release year and date
-BT_RELEASE_YEAR=`date +%Y`
-BT_RELEASE_DATE=`date +%Y-%m-%d`
+release_year_fmt="%Y"
+release_date_fmt="%Y-%m-%d"
+BT_RELEASE_YEAR=`date "+$release_year_fmt"`
+BT_RELEASE_DATE=`date "+$release_date_fmt"`
+if "x$SOURCE_DATE_EPOCH" != "x" ; then
+  BT_RELEASE_YEAR=`date -u -d "@$SOURCE_DATE_EPOCH" "+$release_year_fmt" 
2>/dev/null || date -u -r "$SOURCE_DATE_EPOCH" "+$release_year_fmt" 2>/dev/null 
|| date -u "+$release_year_fmt"`
+  BT_RELEASE_DATE=`date -u -d "@$SOURCE_DATE_EPOCH" "+$release_date_fmt" 
2>/dev/null || date -u -r "$SOURCE_DATE_EPOCH" "+$release_date_fmt" 2>/dev/null 
|| date -u "+$release_date_fmt"`
+fi
 
 AC_SUBST(BT_MAJOR_VERSION)
 AC_SUBST(BT_MINOR_VERSION)
_______________________________________________
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