Source: python-pyqtgraph
Version: 0.11.0-4
Severity: wishlist
Tags: patch
User: [email protected]
Usertags: timestamps
X-Debbugs-Cc: [email protected]
Hi,
Whilst working on the Reproducible Builds effort [0] we noticed that
python-pyqtgraph could not be built reproducibly.
This is because it generates copyright years from the current build
date and therefore will vary on when you build it.
Patch attached that uses SOURCE_DATE_EPOCH [1] for the "current" build
date.
[0] https://reproducible-builds.org/
[1] https://reproducible-builds.org/specs/source-date-epoch/
Regards,
--
,''`.
: :' : Chris Lamb
`. `'` [email protected] / chris-lamb.co.uk
`---- a/debian/patches/reproducible-build.patch 1970-01-01 01:00:00.000000000
+0100
--- b/debian/patches/reproducible-build.patch 2020-06-19 11:22:52.988136344
+0100
@@ -0,0 +1,26 @@
+Description: Make the build reproducible
+Author: Chris Lamb <[email protected]>
+Last-Update: 2020-06-19
+
+--- python-pyqtgraph-0.11.0.orig/doc/source/conf.py
++++ python-pyqtgraph-0.11.0/doc/source/conf.py
+@@ -11,6 +11,7 @@
+ # All configuration values have a default; values that are commented out
+ # serve to show the default.
+
++import time
+ import sys
+ import os
+ from datetime import datetime
+@@ -46,7 +47,10 @@ master_doc = 'index'
+
+ # General information about the project.
+ project = 'pyqtgraph'
+-copyright = '2011 - {}, Luke Campagnola'.format(datetime.now().year)
++now = datetime.utcfromtimestamp(
++ int(os.environ.get('SOURCE_DATE_EPOCH', time.time()))
++)
++copyright = '2011 - {}, Luke Campagnola'.format(now.year)
+
+ # The version info for the project you're documenting, acts as replacement for
+ # |version| and |release|, also used in various other places throughout the
--- a/debian/patches/series 1970-01-01 01:00:00.000000000 +0100
--- b/debian/patches/series 2020-06-19 11:22:51.908128280 +0100
@@ -0,0 +1 @@
+reproducible-build.patch
--
debian-science-maintainers mailing list
[email protected]
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-science-maintainers