From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: bug#25414: [PATCH] gnu: gdk-pixbuf: Make it reproducible. Date: Sun, 15 Jan 2017 02:22:07 +0100 Message-ID: <20170115012207.2604-1-dannym__12142.5037425526$1484443409$gmane$org@scratchpost.org> References: <20170114102117.71ec814d@scratchpost.org> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56823) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cSZXG-00037R-1T for bug-guix@gnu.org; Sat, 14 Jan 2017 20:23:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cSZXC-0005pv-St for bug-guix@gnu.org; Sat, 14 Jan 2017 20:23:06 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:38877) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cSZXC-0005pr-PS for bug-guix@gnu.org; Sat, 14 Jan 2017 20:23:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cSZXC-0004BH-Gz for bug-guix@gnu.org; Sat, 14 Jan 2017 20:23:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <20170114102117.71ec814d@scratchpost.org> List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: guix-devel@gnu.org, 25414@debbugs.gnu.org, Ludovic =?UTF-8?Q?Court=C3=A8s?= * gnu/packages/gtk.scm (gdk-pixbuf): Make it reproducible. --- gnu/local.mk | 1 + gnu/packages/gtk.scm | 3 ++- gnu/packages/patches/gdk-pixbuf-list-dir.patch | 29 ++++++++++++++++++++++++++ 3 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/gdk-pixbuf-list-dir.patch diff --git a/gnu/local.mk b/gnu/local.mk index d37887237..05e6d653f 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -567,6 +567,7 @@ dist_patch_DATA = \ %D%/packages/patches/gcc-6-arm-none-eabi-multilib.patch \ %D%/packages/patches/gcc-6-cross-environment-variables.patch \ %D%/packages/patches/gcj-arm-mode.patch \ + %D%/packages/patches/gdk-pixbuf-list-dir.patch \ %D%/packages/patches/gd-CVE-2016-7568.patch \ %D%/packages/patches/gd-CVE-2016-8670.patch \ %D%/packages/patches/gd-fix-chunk-size-on-boundaries.patch \ diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index b2882b5e9..c4c441f4c 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -434,7 +434,8 @@ highlighting and other features typical of a source code editor.") name "-" version ".tar.xz")) (sha256 (base32 - "0yc8indbl3hf18z6x6kjg59xp9sngm1d8vmz4c7bs6g27qw5npnm")))) + "0yc8indbl3hf18z6x6kjg59xp9sngm1d8vmz4c7bs6g27qw5npnm")) + (patches (search-patches "gdk-pixbuf-list-dir.patch")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--with-x11") diff --git a/gnu/packages/patches/gdk-pixbuf-list-dir.patch b/gnu/packages/patches/gdk-pixbuf-list-dir.patch new file mode 100644 index 000000000..d1427cc38 --- /dev/null +++ b/gnu/packages/patches/gdk-pixbuf-list-dir.patch @@ -0,0 +1,29 @@ +--- gdk-pixbuf-2.34.0/gdk-pixbuf/queryloaders.c.orig 2017-01-11 00:17:32.865843062 +0100 ++++ gdk-pixbuf-2.34.0/gdk-pixbuf/queryloaders.c 2017-01-11 00:31:29.428372177 +0100 +@@ -354,16 +354,25 @@ + + dir = g_dir_open (path, 0, NULL); + if (dir) { ++ GList *entries = NULL; + const char *dent; + + while ((dent = g_dir_read_name (dir))) { + gint len = strlen (dent); + if (len > SOEXT_LEN && + strcmp (dent + len - SOEXT_LEN, SOEXT) == 0) { +- query_module (contents, path, dent); ++ entries = g_list_append (entries, g_strdup (dent)); + } + } + g_dir_close (dir); ++ entries = g_list_sort (entries, strcmp); ++ GList *xentries; ++ for (xentries = entries; xentries; xentries = g_list_next (xentries)) { ++ dent = xentries->data; ++ query_module (contents, path, dent); ++ g_free (xentries->data); ++ } ++ g_list_free (entries); + } + #else + g_string_append_printf (contents, "# dynamic loading of modules not supported\n");