summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2007-12-01 15:35:02 +0000
committerUlrich Müller <ulm@gentoo.org>2007-12-01 15:35:02 +0000
commit11f12043aaaabac9d3686dc75a3d9237a726da05 (patch)
treeef9cefde259576ddc8fbec3b38b0ba7760c286d9 /eclass
parentStable on ppc wrt bug 194265 (diff)
downloadhistorical-11f12043aaaabac9d3686dc75a3d9237a726da05.tar.gz
historical-11f12043aaaabac9d3686dc75a3d9237a726da05.tar.bz2
historical-11f12043aaaabac9d3686dc75a3d9237a726da05.zip
Partial sync from Emacs overlay:
New variable SITEETC. Replace basename by bash parameter expansion.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/elisp-common.eclass22
1 files changed, 13 insertions, 9 deletions
diff --git a/eclass/elisp-common.eclass b/eclass/elisp-common.eclass
index 9d9046971692..9b999b7ba51f 100644
--- a/eclass/elisp-common.eclass
+++ b/eclass/elisp-common.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/elisp-common.eclass,v 1.30 2007/11/17 15:39:35 ulm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/elisp-common.eclass,v 1.31 2007/12/01 15:35:02 ulm Exp $
#
# Copyright 2007 Christian Faulhammer <opfer@gentoo.org>
# Copyright 2002-2004 Matthew Kennedy <mkennedy@gentoo.org>
@@ -129,9 +129,12 @@
# @ECLASS-VARIABLE: SITELISP
# @DESCRIPTION:
-# Directory where Emacs Lisp files are installed.
+# Directory where packages install Emacs Lisp files.
SITELISP=/usr/share/emacs/site-lisp
+# Directory where packages install miscellaneous (not Lisp) files.
+SITEETC=/usr/share/emacs/etc
+
# @ECLASS-VARIABLE: SITEFILE
# @DESCRIPTION:
# Name of package's site-init file.
@@ -256,10 +259,11 @@ elisp-site-file-install() {
local sf="$1" my_pn="${2:-${PN}}"
einfo "Installing site initialisation file for GNU Emacs ..."
cp "${sf}" "${T}"
- sed -i "s:@SITELISP@:${SITELISP}/${my_pn}:g" "${T}/$(basename "${sf}")"
+ sed -i -e "s:@SITELISP@:${SITELISP}/${my_pn}:g" \
+ -e "s:@SITEETC@:${SITEETC}/${my_pn}:g" "${T}/${sf##*/}"
( # subshell to avoid pollution of calling environment
insinto "${SITELISP}"
- doins "${T}/$(basename "${sf}")"
+ doins "${T}/${sf##*/}"
)
}
@@ -303,7 +307,7 @@ elisp-site-regen() {
for sf in "${ROOT}${SITELISP}"/[0-9][0-9]*-gentoo.el
do
[ -r "${sf}" ] || continue
- sflist="${sflist} $(basename "${sf}")"
+ sflist="${sflist} ${sf##*/}"
cat "${sf}" >>"${T}"/site-gentoo.el
done
@@ -335,7 +339,7 @@ elisp-site-regen() {
All site initialisation for Gentoo-installed packages is added to
/usr/share/emacs/site-lisp/site-gentoo.el; site-start.el is no longer
-managed by Gentoo. You are responsible for all maintenance of
+managed by Gentoo. You are responsible for all maintenance of
site-start.el if there is such a file.
In order for this site initialisation to be loaded for all users
@@ -344,9 +348,9 @@ automatically, you can add a line like this:
(require 'site-gentoo)
to /usr/share/emacs/site-lisp/site-start.el. Alternatively, that line
-can be added by individual users to their initialisation files, or for
-greater flexibility, users can select which of the package-specific
-initialisation files in /usr/share/emacs/site-lisp/ to load.
+can be added by individual users to their initialisation files, or,
+for greater flexibility, users can load individual package-specific
+initialisation files from /usr/share/emacs/site-lisp/.
EOF
echo
fi