1 |
commit: cd6b8969ec32e11c022b759c13885fee15ae5005 |
2 |
Author: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Jan 2 14:13:10 2016 +0000 |
4 |
Commit: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Jan 2 15:41:06 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cd6b8969 |
7 |
|
8 |
gnome2.eclass: make use of gnome2_giomodule_cache_update, bug #518422 |
9 |
|
10 |
eclass/gnome2.eclass | 21 +++++++++++++++++++++ |
11 |
1 file changed, 21 insertions(+) |
12 |
|
13 |
diff --git a/eclass/gnome2.eclass b/eclass/gnome2.eclass |
14 |
index 000b3d6..55441b9 100644 |
15 |
--- a/eclass/gnome2.eclass |
16 |
+++ b/eclass/gnome2.eclass |
17 |
@@ -57,6 +57,10 @@ ELTCONF=${ELTCONF:-""} |
18 |
# to handle it properly. It will enable minimal debug with USE=-debug. |
19 |
# Note that this is most commonly found in configure.ac as GNOME_DEBUG_CHECK. |
20 |
|
21 |
+# @ECLASS-VARIABLE: GNOME2_ECLASS_GIO_MODULES |
22 |
+# @INTERNAL |
23 |
+# @DESCRIPTION: |
24 |
+# Array containing glib GIO modules |
25 |
|
26 |
if [[ ${GCONF_DEBUG} != "no" ]]; then |
27 |
IUSE="debug" |
28 |
@@ -241,6 +245,15 @@ gnome2_pkg_preinst() { |
29 |
gnome2_schemas_savelist |
30 |
gnome2_scrollkeeper_savelist |
31 |
gnome2_gdk_pixbuf_savelist |
32 |
+ |
33 |
+ local f |
34 |
+ |
35 |
+ GNOME2_ECLASS_GIO_MODULES=() |
36 |
+ while IFS= read -r -d '' f; do |
37 |
+ GNOME2_ECLASS_GIO_MODULES+=( ${f} ) |
38 |
+ done < <(cd "${D}" && find usr/$(get_libdir)/gio/modules -type f -print0 2>/dev/null) |
39 |
+ |
40 |
+ export GNOME2_ECLASS_GIO_MODULES |
41 |
} |
42 |
|
43 |
# @FUNCTION: gnome2_pkg_postinst |
44 |
@@ -254,6 +267,10 @@ gnome2_pkg_postinst() { |
45 |
gnome2_schemas_update |
46 |
gnome2_scrollkeeper_update |
47 |
gnome2_gdk_pixbuf_update |
48 |
+ |
49 |
+ if [[ ${#GNOME2_ECLASS_GIO_MODULES[@]} -gt 0 ]]; then |
50 |
+ gnome2_giomodule_cache_update |
51 |
+ fi |
52 |
} |
53 |
|
54 |
# # FIXME Handle GConf schemas removal |
55 |
@@ -269,4 +286,8 @@ gnome2_pkg_postrm() { |
56 |
gnome2_icon_cache_update |
57 |
gnome2_schemas_update |
58 |
gnome2_scrollkeeper_update |
59 |
+ |
60 |
+ if [[ ${#GNOME2_ECLASS_GIO_MODULES[@]} -gt 0 ]]; then |
61 |
+ gnome2_giomodule_cache_update |
62 |
+ fi |
63 |
} |