summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2014-11-23 21:46:29 +0000
committerMichał Górny <mgorny@gentoo.org>2014-11-23 21:46:29 +0000
commit12f01736510955c2492fe682f4798b9bebacfd1a (patch)
treeb5565dfc985cd607c53971e1fd4f83b883dc16af /eclass
parentStable for amd64 wrt bug #517380 (diff)
downloadhistorical-12f01736510955c2492fe682f4798b9bebacfd1a.tar.gz
historical-12f01736510955c2492fe682f4798b9bebacfd1a.tar.bz2
historical-12f01736510955c2492fe682f4798b9bebacfd1a.zip
Support multilib in gnome2_query_immodules_gtk2() as well.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/ChangeLog5
-rw-r--r--eclass/gnome2-utils.eclass32
2 files changed, 8 insertions, 29 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog
index d57ec54608d6..2aab3c1711bf 100644
--- a/eclass/ChangeLog
+++ b/eclass/ChangeLog
@@ -1,6 +1,9 @@
# ChangeLog for eclass directory
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1443 2014/11/23 19:56:53 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1444 2014/11/23 21:46:29 mgorny Exp $
+
+ 23 Nov 2014; Michał Górny <mgorny@gentoo.org> gnome2-utils.eclass:
+ Support multilib in gnome2_query_immodules_gtk2() as well.
23 Nov 2014; Pacho Ramos <pacho@gentoo.org> gnome2.eclass:
Deprecate eapis 0 and 1 for gnome2.eclass (#530046)
diff --git a/eclass/gnome2-utils.eclass b/eclass/gnome2-utils.eclass
index 0d72fa9d05c8..5a6b33b5ebb1 100644
--- a/eclass/gnome2-utils.eclass
+++ b/eclass/gnome2-utils.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/gnome2-utils.eclass,v 1.37 2014/11/23 15:00:44 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/gnome2-utils.eclass,v 1.38 2014/11/23 21:46:29 mgorny Exp $
# @ECLASS: gnome2-utils.eclass
# @MAINTAINER:
@@ -439,39 +439,15 @@ gnome2_gdk_pixbuf_update() {
eend $?
}
-
# @FUNCTION: gnome2_query_immodules_gtk2
# @USAGE: gnome2_query_immodules_gtk2
# @DESCRIPTION:
# Updates gtk2 immodules/gdk-pixbuf loaders listing.
gnome2_query_immodules_gtk2() {
- if has_version ">=x11-libs/gtk+-2.24.20:2"; then
- "${EPREFIX}/usr/bin/gtk-query-immodules-2.0" --update-cache
- else
- local GTK2_CONFDIR="/etc/gtk-2.0/$(get_abi_CHOST)"
-
- local query_exec="${EPREFIX}/usr/bin/gtk-query-immodules-2.0"
- local gtk_conf="${EPREFIX}${GTK2_CONFDIR}/gtk.immodules"
- local gtk_conf_dir=$(dirname "${gtk_conf}")
-
- einfo "Generating Gtk2 immodules/gdk-pixbuf loaders listing:"
- einfo "-> ${gtk_conf}"
-
- mkdir -p "${gtk_conf_dir}"
- local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgtk_query_immodules)
- if [ -z "${tmp_file}" ]; then
- ewarn "gtk_query_immodules: cannot create temporary file"
- return 1
- fi
+ local updater=${EPREFIX}/usr/bin/${CHOST}-gtk-query-immodules-2.0
+ [[ ! -x ${updater} ]] && updater=${EPREFIX}/usr/bin/gtk-query-immodules-2.0
- if ${query_exec} > "${tmp_file}"; then
- cat "${tmp_file}" > "${gtk_conf}" || \
- ewarn "Failed to write to ${gtk_conf}"
- else
- ewarn "Cannot update gtk.immodules, file generation failed"
- fi
- rm "${tmp_file}"
- fi
+ "${updater}" --update-cache
}
# @FUNCTION: gnome2_query_immodules_gtk3