Source: ne Version: 3.3.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 ne could not be built reproducibly. This is because it embeds the current build date. 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/04_reproducible_build.diff 1969-12-31 16:00:00.000000000 -0800 --- b/debian/patches/04_reproducible_build.diff 2025-10-22 10:26:25.440459873 -0700 @@ -0,0 +1,20 @@ +Description: Make the build reproducible +Author: Chris Lamb <[email protected]> +Last-Update: 2025-10-22 + +--- ne-3.3.4.orig/version.pl ++++ ne-3.3.4/version.pl +@@ -35,9 +35,10 @@ unless ( $version ) + print "$0: could not determine version.\n"; + exit 0; + } +-my $year = 1900 + (localtime(time()))[5]; +-my $month = substr("00" . (1+(localtime(time()))[4]), -2); +-my $date = substr("00" . ( (localtime(time()))[3]), -2); ++my @timestamp = gmtime($ENV{SOURCE_DATE_EPOCH} || time); ++my $year = 1900 + $timestamp[5]; ++my $month = substr("00" . (1 + $timestamp[4]), -2); ++my $date = substr("00" . $timestamp[3], -2); + + open NE_VERSION_TEXINFO, ">doc/version.texinfo"; + print NE_VERSION_TEXINFO qq[\@ignore --- a/debian/patches/series 2025-10-22 09:52:10.000237678 -0700 --- b/debian/patches/series 2025-10-22 10:25:30.006808760 -0700 @@ -1 +1,2 @@ 03_allow_cflags_override.diff +04_reproducible_build.diff

