[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
44/97: gnu: gtk+-2: Look in system data dirs for themes.
From: |
Ludovic Courtès |
Subject: |
44/97: gnu: gtk+-2: Look in system data dirs for themes. |
Date: |
Wed, 13 Apr 2016 17:31:47 +0000 |
civodul pushed a commit to branch gnome-updates
in repository guix.
commit a0dbfcf8cddad9c302c826c0fe59af5901215d0b
Author: Jookia <address@hidden>
Date: Wed Apr 6 21:00:58 2016 +0800
gnu: gtk+-2: Look in system data dirs for themes.
* gnu/packages/patches/gtk2-theme-paths.patch: New patch.
* gnu/packages/gtk.scm (gtk+-2)[source]: Use it.
* gnu-system.am (dist_patch_DATA): Add it.
Signed-off-by: å®‹æ–‡æ¦ <address@hidden>
---
gnu-system.am | 1 +
gnu/packages/gtk.scm | 3 +-
gnu/packages/patches/gtk2-theme-paths.patch | 41 +++++++++++++++++++++++++++
3 files changed, 44 insertions(+), 1 deletions(-)
diff --git a/gnu-system.am b/gnu-system.am
index 22b4cc3..f70c723 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -511,6 +511,7 @@ dist_patch_DATA =
\
gnu/packages/patches/guile-relocatable.patch \
gnu/packages/patches/guile-rsvg-pkgconfig.patch \
gnu/packages/patches/gtk2-respect-GUIX_GTK2_PATH.patch \
+ gnu/packages/patches/gtk2-theme-paths.patch \
gnu/packages/patches/gtk3-respect-GUIX_GTK3_PATH.patch \
gnu/packages/patches/gtkglext-disable-disable-deprecated.patch \
gnu/packages/patches/hop-bigloo-4.0b.patch \
diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm
index ff9b420..0e53393 100644
--- a/gnu/packages/gtk.scm
+++ b/gnu/packages/gtk.scm
@@ -557,7 +557,8 @@ is part of the GNOME accessibility project.")
(sha256
(base32
"0l6aqk86aw5w132ygy6hv6nlxvd1h6xg7c85qbm60p6mnv1ww58d"))
- (patches (list (search-patch
"gtk2-respect-GUIX_GTK2_PATH.patch")))))
+ (patches (list (search-patch "gtk2-respect-GUIX_GTK2_PATH.patch")
+ (search-patch "gtk2-theme-paths.patch")))))
(build-system gnu-build-system)
(outputs '("out" "doc"))
(propagated-inputs
diff --git a/gnu/packages/patches/gtk2-theme-paths.patch
b/gnu/packages/patches/gtk2-theme-paths.patch
new file mode 100644
index 0000000..6c1351e
--- /dev/null
+++ b/gnu/packages/patches/gtk2-theme-paths.patch
@@ -0,0 +1,41 @@
+From: Jookia <address@hidden>
+Subject: [PATCHv2] gtk: Patch GTK+ to look for themes in profiles.
+To: address@hidden
+Date: Sun, 13 Mar 2016 15:17:37 +1100
+Url: https://lists.gnu.org/archive/html/guix-devel/2016-03/msg00492.html
+
+diff -Naur gtk+-2.24.28.new/gtk/gtkrc.c gtk+-2.24.28/gtk/gtkrc.c
+--- gtk+-2.24.28.new/gtk/gtkrc.c 2016-03-13 10:31:14.413644362 +1100
++++ gtk+-2.24.28/gtk/gtkrc.c 2016-03-13 12:51:34.723398423 +1100
+@@ -808,6 +808,8 @@
+ gchar *path = NULL;
+ const gchar *home_dir;
+ gchar *subpath;
++ const gchar * const *xdg_data_dirs;
++ gint i;
+
+ if (type)
+ subpath = g_strconcat ("gtk-2.0-", type,
+@@ -830,6 +832,22 @@
+ }
+
+ if (!path)
++ {
++ xdg_data_dirs = g_get_system_data_dirs ();
++ for (i = 0; xdg_data_dirs[i]; i++)
++ {
++ path = g_build_filename (xdg_data_dirs[i], "themes", name, subpath,
NULL);
++ if (g_file_test (path, G_FILE_TEST_EXISTS))
++ break;
++ else
++ {
++ g_free (path);
++ path = NULL;
++ }
++ }
++ }
++
++ if (!path)
+ {
+ gchar *theme_dir = gtk_rc_get_theme_dir ();
+ path = g_build_filename (theme_dir, name, subpath, NULL);
- 37/97: gnu: gdk-pixbuf: Propagate shared-mime-info., (continued)
- 37/97: gnu: gdk-pixbuf: Propagate shared-mime-info., Ludovic Courtès, 2016/04/13
- 25/97: gnu: at-spi2-core: Update to 2.20.0., Ludovic Courtès, 2016/04/13
- 13/97: gnu: glib: Disable tests in build phases instead of patches., Ludovic Courtès, 2016/04/13
- 34/97: gnu: gnome-keyring: Update to 3.20.0., Ludovic Courtès, 2016/04/13
- 41/97: gnu: libcroco: Update to 0.6.11., Ludovic Courtès, 2016/04/13
- 43/97: gnu: glade: Use 'glib-or-gtk-build-system'., Ludovic Courtès, 2016/04/13
- 10/97: gnu: freetype: Add libpng and zlib to propagated-inputs., Ludovic Courtès, 2016/04/13
- 48/97: gnu: gnumeric: Update to 1.12.28., Ludovic Courtès, 2016/04/13
- 24/97: gnu: gtksourceview: Update to 3.20.1., Ludovic Courtès, 2016/04/13
- 47/97: gnu: goffice: Update to 0.10.28., Ludovic Courtès, 2016/04/13
- 44/97: gnu: gtk+-2: Look in system data dirs for themes.,
Ludovic Courtès <=
- 59/97: gnu: libsecret: Update to 0.18.5., Ludovic Courtès, 2016/04/13
- 62/97: gnu: geocode-glib: Update to 3.20.0., Ludovic Courtès, 2016/04/13
- 58/97: gnu: libsoup: Update to 2.54.0.1., Ludovic Courtès, 2016/04/13
- 57/97: gnu: glib-networking: Update to 2.48.0., Ludovic Courtès, 2016/04/13
- 05/97: gnu: gobject-introspection: Remove cairo from inputs., Ludovic Courtès, 2016/04/13
- 45/97: gnu: libgnomeprint: Fix build., Ludovic Courtès, 2016/04/13
- 56/97: gnu: json-glib: Update to 1.2.0., Ludovic Courtès, 2016/04/13
- 40/97: gnu: glade: Update to 3.20.0., Ludovic Courtès, 2016/04/13
- 65/97: gnu: totem-pl-parser: Update to 3.10.6., Ludovic Courtès, 2016/04/13
- 82/97: gnu: gnome-session: Update to 3.20.0., Ludovic Courtès, 2016/04/13