Source: air-quality-sensor
Version: 0.1.3-1
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], we noticed that 
air-quality-sensor could not be built reproducibly.

Patch attached.

 [0] https://wiki.debian.org/ReproducibleBuilds


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
--- a/debian/patches/reproducible_build.patch   1970-01-01 01:00:00.000000000 
+0100
--- b/debian/patches/reproducible_build.patch   2015-12-26 10:12:25.685942562 
+0000
@@ -0,0 +1,16 @@
+--- air-quality-sensor-0.1.3.orig/configure.ac
++++ air-quality-sensor-0.1.3/configure.ac
+@@ -8,7 +8,12 @@ AC_CHECK_FUNCS(getopt_long)
+ 
+ dnl Copyright will apply as long as these sources are in use, e.g., are
+ dnl being compiled, which is reasonable year to claim the copyright.
+-AC_DEFINE([COPYRIGHT_YEAR], [m4_esyscmd([date +%Y])], [year in copyright 
message])
++if test "x$SOURCE_DATE_EPOCH" = "x"; then
++    year=m4_esyscmd([date +%Y])
++else
++    year=`date -u -d "@$SOURCE_DATE_EPOCH" "+%Y" 2>/dev/null || date -u -r 
"$SOURCE_DATE_EPOCH" "+%Y" 2>/dev/null || date -u "+%Y"`
++fi
++AC_DEFINE_UNQUOTED([COPYRIGHT_YEAR], ["$year"], [year in copyright message])
+ 
+ libusb_is_old=0
+ AC_CHECK_LIB(usb-1.0, libusb_get_parent, [], [libusb_is_old=1])
--- a/debian/patches/series     1970-01-01 01:00:00.000000000 +0100
--- b/debian/patches/series     2015-12-26 09:51:55.930653536 +0000
@@ -0,0 +1 @@
+reproducible_build.patch
_______________________________________________
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