summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMart Raudsepp <leio@gentoo.org>2019-02-10 21:37:21 +0200
committerMart Raudsepp <leio@gentoo.org>2019-02-11 19:14:13 +0200
commit1b183b8fb6e5c0ce2265265556fe5d061b959f79 (patch)
tree74bac4ba83f1d90a2edf2acb0d74abc69996915b /eclass/gnome2-utils.eclass
parentxdg-utils: Clarify icon cache comment to not suggest GTK only (diff)
downloadgentoo-1b183b8fb6e5c0ce2265265556fe5d061b959f79.tar.gz
gentoo-1b183b8fb6e5c0ce2265265556fe5d061b959f79.tar.bz2
gentoo-1b183b8fb6e5c0ce2265265556fe5d061b959f79.zip
gnome2-utils: Don't provide icon cache functions with EAPI-7
They are in xdg-utils now, so EAPI-7 bump is a good time to move over to the xdg versions by those that need it. Signed-off-by: Mart Raudsepp <leio@gentoo.org>
Diffstat (limited to 'eclass/gnome2-utils.eclass')
-rw-r--r--eclass/gnome2-utils.eclass50
1 files changed, 28 insertions, 22 deletions
diff --git a/eclass/gnome2-utils.eclass b/eclass/gnome2-utils.eclass
index 41b3edbcd9b4..8ba576aab8c7 100644
--- a/eclass/gnome2-utils.eclass
+++ b/eclass/gnome2-utils.eclass
@@ -198,28 +198,6 @@ gnome2_gconf_uninstall() {
fi
}
-# @FUNCTION: gnome2_icon_savelist
-# @DESCRIPTION:
-# Find the icons that are about to be installed and save their location
-# in the GNOME2_ECLASS_ICONS environment variable. This is only
-# necessary for eclass implementations that call
-# gnome2_icon_cache_update conditionally.
-# This function should be called from pkg_preinst.
-gnome2_icon_savelist() {
- has ${EAPI:-0} 0 1 2 && ! use prefix && ED="${D}"
- pushd "${ED}" > /dev/null || die
- export GNOME2_ECLASS_ICONS=$(find 'usr/share/icons' -maxdepth 1 -mindepth 1 -type d 2> /dev/null)
- popd > /dev/null || die
-}
-
-# @FUNCTION: gnome2_icon_cache_update
-# @DESCRIPTION:
-# Updates Gtk+ icon cache files under /usr/share/icons.
-# Deprecated. Please use xdg_icon_cache_update from xdg-utils.eclass
-gnome2_icon_cache_update() {
- xdg_icon_cache_update
-}
-
# @FUNCTION: gnome2_omf_fix
# @DESCRIPTION:
# Workaround applied to Makefile rules in order to remove redundant
@@ -472,3 +450,31 @@ gnome2_disable_deprecation_warning() {
ewarn "Failed to disable deprecation warnings in ${makefile}"
done
}
+
+case ${EAPI:-0} in
+0|1|2|3|4|5|6)
+
+# @FUNCTION: gnome2_icon_savelist
+# @DESCRIPTION:
+# Find the icons that are about to be installed and save their location
+# in the GNOME2_ECLASS_ICONS environment variable. This is only
+# necessary for eclass implementations that call
+# gnome2_icon_cache_update conditionally.
+# This function should be called from pkg_preinst.
+gnome2_icon_savelist() {
+ has ${EAPI:-0} 0 1 2 && ! use prefix && ED="${D}"
+ pushd "${ED}" > /dev/null || die
+ export GNOME2_ECLASS_ICONS=$(find 'usr/share/icons' -maxdepth 1 -mindepth 1 -type d 2> /dev/null)
+ popd > /dev/null || die
+}
+
+# @FUNCTION: gnome2_icon_cache_update
+# @DESCRIPTION:
+# Updates Gtk+ icon cache files under /usr/share/icons.
+# Deprecated. Please use xdg_icon_cache_update from xdg-utils.eclass
+gnome2_icon_cache_update() {
+ xdg_icon_cache_update
+}
+
+;;
+esac