From 604f9dba2f88ce3446f7f5ef5b16f5f8eb69f1d9 Mon Sep 17 00:00:00 2001 From: Ulrich Müller Date: Fri, 20 Dec 2019 08:53:49 +0100 Subject: Revert "elisp-common.eclass: Drop support for EAPIs 0 to 3." MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This wasn't correct. doins will indeed die by itself since EAPI 4, but die in a subshell is not guaranteed to work before EAPI 7. This reverts commit 72855c617981e1f1191a0ab2a9589d90c27f1b68. Signed-off-by: Ulrich Müller --- eclass/elisp-common.eclass | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'eclass/elisp-common.eclass') diff --git a/eclass/elisp-common.eclass b/eclass/elisp-common.eclass index 79f29ef95ad9..05b03f493957 100644 --- a/eclass/elisp-common.eclass +++ b/eclass/elisp-common.eclass @@ -1,4 +1,4 @@ -# Copyright 2002-2019 Gentoo Authors +# Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: elisp-common.eclass @@ -10,7 +10,6 @@ # Mamoru Komachi # Christian Faulhammer # Ulrich Müller -# @SUPPORTED_EAPIS: 4 5 6 7 # @BLURB: Emacs-related installation utilities # @DESCRIPTION: # @@ -157,11 +156,6 @@ # environment, so it is no problem when you unset USE=emacs between # merge and unmerge of a package. -case ${EAPI:-0} in - 4|5|6|7) ;; - *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; -esac - # @ECLASS-VARIABLE: SITELISP # @DESCRIPTION: # Directory where packages install Emacs Lisp files. @@ -304,11 +298,12 @@ elisp-make-autoload-file() { elisp-install() { local subdir="$1" shift - einfo "Installing Elisp files for GNU Emacs support" + ebegin "Installing Elisp files for GNU Emacs support" ( # subshell to avoid pollution of calling environment insinto "${SITELISP}/${subdir}" doins "$@" ) + eend $? "elisp-install: doins failed" || die } # @FUNCTION: elisp-site-file-install @@ -321,14 +316,14 @@ elisp-install() { # respectively. elisp-site-file-install() { - local sf="${1##*/}" my_pn="${2:-${PN}}" + local sf="${1##*/}" my_pn="${2:-${PN}}" ret local header=";;; ${PN} site-lisp configuration" [[ ${sf} == [0-9][0-9]*-gentoo*.el ]] \ || ewarn "elisp-site-file-install: bad name of site-init file" [[ ${sf%-gentoo*.el} != "${sf}" ]] && sf="${sf%-gentoo*.el}-gentoo.el" - einfo "Installing site-init file ${sf} for GNU Emacs" sf="${T}/${sf}" + ebegin "Installing site initialisation file for GNU Emacs" [[ $1 = "${sf}" ]] || cp "$1" "${sf}" sed -i -e "1{:x;/^\$/{n;bx;};/^;.*${PN}/I!s:^:${header}\n\n:;1s:^:\n:;}" \ -e "s:@SITELISP@:${EPREFIX}${SITELISP}/${my_pn}:g" \ @@ -337,7 +332,9 @@ elisp-site-file-install() { insinto "${SITELISP}/site-gentoo.d" doins "${sf}" ) + ret=$? rm -f "${sf}" + eend ${ret} "elisp-site-file-install: doins failed" || die } # @FUNCTION: elisp-site-regen -- cgit v1.2.3-65-gdbad