Source: rsync Version: 3.2.4-1 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 rsync could not be built reproducibly. This was because the manpage generation used the current date for the manual page header. A patch is attached that will use SOURCE_DATE_EPOCH if available. [0] https://reproducible-builds.org/ Regards, -- ,''`. : :' : Chris Lamb `. `'` [email protected] / chris-lamb.co.uk `-
--- a/debian/patches/reproducible_manpages.patch 1969-12-31 16:00:00.000000000 -0800 --- b/debian/patches/reproducible_manpages.patch 2022-04-21 09:29:18.220183086 -0700 @@ -0,0 +1,15 @@ +Description: Make the build reproducible +Author: Chris Lamb <[email protected]> +Last-Update: 2022-04-21 + +--- rsync-3.2.4.orig/md-convert ++++ rsync-3.2.4/md-convert +@@ -241,7 +241,7 @@ def find_man_substitutions(): + if var == 'srcdir': + break + +- env_subs['date'] = time.strftime('%d %b %Y', time.localtime(mtime)) ++ env_subs['date'] = time.strftime('%d %b %Y', time.gmtime(int(os.environ.get('SOURCE_DATE_EPOCH', time.time())))) + + + def html_via_commonmark(txt): --- a/debian/patches/series 2022-04-21 09:16:56.694213519 -0700 --- b/debian/patches/series 2022-04-21 09:29:17.192187237 -0700 @@ -2,3 +2,4 @@ skip_devices_test.patch perl_shebang.patch fix_rrsync_man_generation.patch +reproducible_manpages.patch

