--- a/debian/patches/reproducible-build.patch 1970-01-01 01:00:00.000000000 +0100 --- b/debian/patches/reproducible-build.patch 2020-07-13 12:30:17.783317854 +0100 @@ -0,0 +1,26 @@ +Description: Make the build reproducible +Author: Chris Lamb +Last-Update: 2020-07-13 + +--- pyerfa-1.7.0+ds.orig/docs/conf.py ++++ pyerfa-1.7.0+ds/docs/conf.py +@@ -27,6 +27,7 @@ + + from datetime import datetime + import sys ++import os, time + + from pkg_resources import get_distribution + +@@ -41,7 +42,10 @@ except ImportError: + + project = 'PyERFA' + author = 'The PyERFA Developers' +-copyright = '2011\u2013{0}, {1}'.format(datetime.utcnow().year, author) ++build_date = datetime.utcfromtimestamp( ++ int(os.environ.get('SOURCE_DATE_EPOCH', time.time())) ++) ++copyright = '2011\u2013{0}, {1}'.format(build_date.year, author) + + # 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-07-13 12:30:16.695345996 +0100 @@ -0,0 +1 @@ +reproducible-build.patch