Source: jam
Version: 2.6-1
Severity: wishlist
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: locale
X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org

Hi!

While working on the "reproducible builds" effort [1], we have noticed
that jam could not be built reproducibly.
A list is sorted differently depending on the configured locale.

The attached patch fixes this by sorting with the locale set to C.

Regards,
 Reiner

[1]: https://wiki.debian.org/ReproducibleBuilds

diff --git a/debian/patches/reproducible_build.patch b/debian/patches/reproducible_build.patch
new file mode 100644
index 0000000..505a0a0
--- /dev/null
+++ b/debian/patches/reproducible_build.patch
@@ -0,0 +1,16 @@
+Author: Reiner Herrmann <rei...@reiner-h.de>
+Description: locale-independent sort to get reproducible result
+
+Index: jam-2.6/yyacc
+===================================================================
+--- jam-2.6.orig/yyacc
++++ jam-2.6/yyacc
+@@ -41,7 +41,7 @@ sed '
+ 		b 1
+ 	}
+ 	d
+-' $in | sort -u | sed '
++' $in | LC_ALL=C sort -u | sed '
+ 	h
+ 	y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/
+ 	s/:/_COLON/
diff --git a/debian/patches/series b/debian/patches/series
index 5c8d533..469f572 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@ typos.patch
 debian-docpaths.patch
 jambase-clarification.patch
 installmodes.patch
+reproducible_build.patch

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds

Reply via email to