summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2008-04-04 18:11:28 +0000
committerUlrich Müller <ulm@gentoo.org>2008-04-04 18:11:28 +0000
commit1f7bb3fe5d44d7a42d3c3326e263d5d41dae424b (patch)
treec84afa160017807100e6b09617bf06b945836a05 /eclass
parentNew version released, Bug 215596 (diff)
downloadgentoo-2-1f7bb3fe5d44d7a42d3c3326e263d5d41dae424b.tar.gz
gentoo-2-1f7bb3fe5d44d7a42d3c3326e263d5d41dae424b.tar.bz2
gentoo-2-1f7bb3fe5d44d7a42d3c3326e263d5d41dae424b.zip
Sync eclasses from Emacs overlay (revision 1041).
elisp-common.eclass: Check if the SITELISP directory exists.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/elisp-common.eclass12
1 files changed, 9 insertions, 3 deletions
diff --git a/eclass/elisp-common.eclass b/eclass/elisp-common.eclass
index 11d09451771d..4654e75d23bb 100644
--- a/eclass/elisp-common.eclass
+++ b/eclass/elisp-common.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/elisp-common.eclass,v 1.37 2008/03/07 08:19:19 ulm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/elisp-common.eclass,v 1.38 2008/04/04 18:11:28 ulm Exp $
#
# Copyright 2002-2004 Matthew Kennedy <mkennedy@gentoo.org>
# Copyright 2003 Jeremy Maitin-Shepard <jbms@attbi.com>
@@ -141,7 +141,7 @@ SITEETC=/usr/share/emacs/etc
SITEFILE=50${PN}-gentoo.el
EMACS=/usr/bin/emacs
-# The following works for Emacs versions 18--23, don't change it.
+# The following works for Emacs versions 18-23, don't change it.
EMACSFLAGS="-batch -q --no-site-file"
# @FUNCTION: elisp-compile
@@ -200,7 +200,7 @@ elisp-comp() {
# Output version of currently active Emacs.
elisp-emacs-version() {
- # The following will work for at least versions 18--23.
+ # The following will work for at least versions 18-23.
echo "(princ emacs-version)" >"${T}"/emacs-version.el
${EMACS} ${EMACSFLAGS} -l "${T}"/emacs-version.el
rm -f "${T}"/emacs-version.el
@@ -288,8 +288,14 @@ elisp-site-file-install() {
elisp-site-regen() {
local i sf line obsolete
local -a sflist
+ # Work around Paludis borkage: variable T is empty in pkg_postrm
local tmpdir=${T:-/tmp}
+ if [ ! -d "${ROOT}${SITELISP}" ]; then
+ eerror "Directory ${SITELISP} does not exist"
+ return 1
+ fi
+
if [ ! -e "${ROOT}${SITELISP}"/site-gentoo.el ] \
&& [ ! -e "${ROOT}${SITELISP}"/site-start.el ]; then
einfo "Creating default ${SITELISP}/site-start.el ..."