commit:     25949b8e668f06975c2b42501ad608b59fd7c928
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Mon Feb 15 08:40:27 2021 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Mon Feb 15 08:41:34 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=25949b8e

elisp-common.eclass: More verbose error for failed version detection

Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>

 eclass/elisp-common.eclass | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/eclass/elisp-common.eclass b/eclass/elisp-common.eclass
index 66a3a325e67..be8d0fa3b30 100644
--- a/eclass/elisp-common.eclass
+++ b/eclass/elisp-common.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 # @ECLASS: elisp-common.eclass
@@ -234,6 +234,8 @@ elisp-emacs-version() {
        rm -f "${T}"/emacs-version.el
        if [[ ${ret} -ne 0 ]]; then
                eerror "elisp-emacs-version: Failed to run ${EMACS}"
+               [[ $(realpath ${EMACS} 2>/dev/null) == */emacs* ]] \
+                       || eerror "This package needs GNU Emacs"
                return ${ret}
        fi
        if [[ -z ${version} ]]; then

Reply via email to