summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorGilles Dartiguelongue <eva@gentoo.org>2015-05-25 18:07:47 +0200
committerGilles Dartiguelongue <eva@gentoo.org>2015-05-25 18:07:47 +0200
commitf1f7e5b963209fefcc2acc77261dd7eb69700165 (patch)
tree57ca7dc7a001d8453a7ad268e00434f9d8e62782 /eclass
parenteclass: add XDG eclass to replace fdo-mime (diff)
downloadgnome-f1f7e5b963209fefcc2acc77261dd7eb69700165.tar.gz
gnome-f1f7e5b963209fefcc2acc77261dd7eb69700165.tar.bz2
gnome-f1f7e5b963209fefcc2acc77261dd7eb69700165.zip
eclass/gnome2.eclass: switch to xdg eclass
Diffstat (limited to 'eclass')
-rw-r--r--eclass/gnome2-utils.eclass12
-rw-r--r--eclass/gnome2.eclass11
2 files changed, 6 insertions, 17 deletions
diff --git a/eclass/gnome2-utils.eclass b/eclass/gnome2-utils.eclass
index 4c7d0c8e..650c57d0 100644
--- a/eclass/gnome2-utils.eclass
+++ b/eclass/gnome2-utils.eclass
@@ -95,18 +95,6 @@ gnome2_environment_reset() {
# GST_REGISTRY is to work around gst utilities trying to read/write /root
export GST_REGISTRY="${T}/registry.xml"
-
- # XXX: code for resetting XDG_* directories should probably be moved into
- # a separate function in a non-gnome eclass
- export XDG_DATA_HOME="${T}/.local/share"
- export XDG_CONFIG_HOME="${T}/.config"
- export XDG_CACHE_HOME="${T}/.cache"
- export XDG_RUNTIME_DIR="${T}/run"
- mkdir -p "${XDG_DATA_HOME}" "${XDG_CONFIG_HOME}" "${XDG_CACHE_HOME}" \
- "${XDG_RUNTIME_DIR}"
- # This directory needs to be owned by the user, and chmod 0700
- # http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html
- chmod 0700 "${XDG_RUNTIME_DIR}"
}
# @FUNCTION: gnome2_gconf_savelist
diff --git a/eclass/gnome2.eclass b/eclass/gnome2.eclass
index 9d1730d1..7fc3423c 100644
--- a/eclass/gnome2.eclass
+++ b/eclass/gnome2.eclass
@@ -10,7 +10,7 @@
# Exports portage base functions used by ebuilds written for packages using the
# GNOME framework. For additional functions, see gnome2-utils.eclass.
-inherit eutils fdo-mime libtool gnome.org gnome2-utils
+inherit eutils libtool gnome.org gnome2-utils xdg
case "${EAPI:-0}" in
4|5)
@@ -75,6 +75,8 @@ gnome2_src_unpack() {
# Prepare environment for build, fix build of scrollkeeper documentation,
# run elibtoolize.
gnome2_src_prepare() {
+ xdg_src_prepare
+
# Prevent assorted access violations and test failures
gnome2_environment_reset
@@ -239,6 +241,7 @@ gnome2_src_install() {
# @DESCRIPTION:
# Finds Icons, GConf and GSettings schemas for later handling in pkg_postinst
gnome2_pkg_preinst() {
+ xdg_pkg_preinst
gnome2_gconf_savelist
gnome2_icon_savelist
gnome2_schemas_savelist
@@ -251,9 +254,8 @@ gnome2_pkg_preinst() {
# Handle scrollkeeper, GConf, GSettings, Icons, desktop and mime
# database updates.
gnome2_pkg_postinst() {
+ xdg_pkg_postinst
gnome2_gconf_install
- fdo-mime_desktop_database_update
- fdo-mime_mime_database_update
gnome2_icon_cache_update
gnome2_schemas_update
gnome2_scrollkeeper_update
@@ -276,8 +278,7 @@ gnome2_pkg_postinst() {
# @DESCRIPTION:
# Handle scrollkeeper, GSettings, Icons, desktop and mime database updates.
gnome2_pkg_postrm() {
- fdo-mime_desktop_database_update
- fdo-mime_mime_database_update
+ xdg_pkg_postrm
gnome2_icon_cache_update
gnome2_schemas_update
gnome2_scrollkeeper_update