Bug#845524: cairo-5c: please make the build reproducible

Chris Lamb lamby at debian.org
Thu Nov 24 09:03:36 UTC 2016


Source: cairo-5c
Version: 1.9
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 cairo-5c could not be built reproducibly.

Patch attached.

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


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby at debian.org / chris-lamb.co.uk
       `-
-------------- next part --------------
diff --git a/Makefile.am b/Makefile.am
index fac5383..4aa1b80 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -34,7 +34,12 @@
 
 SUBDIRS = src nichrome test examples
 
-BUILD_DATE=$(shell date +"%F")
+ifdef SOURCE_DATE_EPOCH
+	BUILD_DATE=$(shell date -u -d "@$(SOURCE_DATE_EPOCH)" +"%F"  2>/dev/null || date -u -r "$(SOURCE_DATE_EPOCH)" +"%F" 2>/dev/null || date -u +"%F")
+else
+	BUILD_DATE=$(shell date +"%F")
+endif
+
 NICKLE_VERSION=$(shell nickle -e version | sed 's/"//g')
 
 RELEASE_UPLOAD_HOST =   cairographics.org


More information about the Reproducible-bugs mailing list