Source: libxray-scattering-perl Version: 3.0.1-1 Severity: wishlist Tags: patch User: [email protected] Usertags: randomness X-Debbugs-CC: [email protected]
Hi! While working on Debian's “reproducible builds” effort [1], we have noticed that libxray-scattering-perl doesn't build reproducibly. Two files generated by perl scripts are not generated deterministically. The attached patch fixes this by telling Storable::nstore to produce sorted output. Regards, Reiner [1]: https://wiki.debian.org/ReproducibleBuilds
diff --git a/debian/patches/reproducible_db.patch b/debian/patches/reproducible_db.patch new file mode 100644 index 0000000..95df2df --- /dev/null +++ b/debian/patches/reproducible_db.patch @@ -0,0 +1,29 @@ +Author: Reiner Herrmann <[email protected]> +Description: Set $Storable::canonical to 1 to get reproducible output for nstore + +Index: libxray-scattering-perl-3.0.1/data/cromann.PL +=================================================================== +--- libxray-scattering-perl-3.0.1.orig/data/cromann.PL ++++ libxray-scattering-perl-3.0.1/data/cromann.PL +@@ -31,6 +31,8 @@ use Storable qw/nstore/; + use File::Spec; + use Chemistry::Elements qw(get_symbol); + ++$Storable::canonical = 1; ++ + ##data (s(i),i=1,214) / + my @symbols = ( + 'h', 'h.', 'h1-', 'he', 'li', 'li1+', 'be', +Index: libxray-scattering-perl-3.0.1/data/waaskirf.PL +=================================================================== +--- libxray-scattering-perl-3.0.1.orig/data/waaskirf.PL ++++ libxray-scattering-perl-3.0.1/data/waaskirf.PL +@@ -36,6 +36,8 @@ use Storable qw/nstore/; + use File::Spec; + use Chemistry::Elements qw(get_symbol); + ++$Storable::canonical = 1; ++ + ##data (s(i),i=1,214) / + + my @symbols = qw(H H1- He Li Li1+ Be Be2+ B C Cval N O O1- O2- F F1- Ne Na diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..4be9e98 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1 @@ +reproducible_db.patch
signature.asc
Description: OpenPGP digital signature

