Gentoo Archives: gentoo-dev

From: "Ulrich Müller" <ulm@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] [PATCH] elisp.eclass: Drop support for EAPIs 0 to 3.
Date: Mon, 15 Jul 2019 08:08:07
Message-Id: w6gmuhflnzb.fsf@kph.uni-mainz.de
1 Signed-off-by: Ulrich Müller <ulm@g.o>
2 ---
3 eclass/elisp.eclass | 36 +++++++++++++-----------------------
4 1 file changed, 13 insertions(+), 23 deletions(-)
5
6 diff --git a/eclass/elisp.eclass b/eclass/elisp.eclass
7 index 55635398d54..c885345a7a8 100644
8 --- a/eclass/elisp.eclass
9 +++ b/eclass/elisp.eclass
10 @@ -1,4 +1,4 @@
11 -# Copyright 1999-2018 Gentoo Foundation
12 +# Copyright 1999-2019 Gentoo Authors
13 # Distributed under the terms of the GNU General Public License v2
14
15 # @ECLASS: elisp.eclass
16 @@ -9,7 +9,7 @@
17 # Jeremy Maitin-Shepard <jbms@×××××.com>
18 # Christian Faulhammer <fauli@g.o>
19 # Ulrich Müller <ulm@g.o>
20 -# @SUPPORTED_EAPIS: 0 1 2 3 4 5 6 7
21 +# @SUPPORTED_EAPIS: 4 5 6 7
22 # @BLURB: Eclass for Emacs Lisp packages
23 # @DESCRIPTION:
24 #
25 @@ -67,21 +67,17 @@
26
27 inherit elisp-common
28 case ${EAPI:-0} in
29 - 0|1|2|3|4|5) inherit epatch ;;
30 + 4|5) inherit epatch ;;
31 6|7) ;;
32 - *) die "${ECLASS}: EAPI ${EAPI} not supported" ;;
33 + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
34 esac
35
36 -case ${EAPI:-0} in
37 - 0|1) EXPORT_FUNCTIONS src_{unpack,compile,install} \
38 - pkg_{setup,postinst,postrm} ;;
39 - *) EXPORT_FUNCTIONS src_{unpack,prepare,configure,compile,install} \
40 - pkg_{setup,postinst,postrm} ;;
41 -esac
42 +EXPORT_FUNCTIONS src_{unpack,prepare,configure,compile,install} \
43 + pkg_{setup,postinst,postrm}
44
45 RDEPEND=">=virtual/emacs-${NEED_EMACS:-23}"
46 -case ${EAPI:-0} in
47 - 0|1|2|3|4|5|6) DEPEND="${RDEPEND}" ;;
48 +case ${EAPI} in
49 + 4|5|6) DEPEND="${RDEPEND}" ;;
50 *) BDEPEND="${RDEPEND}" ;;
51 esac
52
53 @@ -102,8 +98,7 @@ elisp_pkg_setup() {
54 # @FUNCTION: elisp_src_unpack
55 # @DESCRIPTION:
56 # Unpack the sources; also handle the case of a single *.el file in
57 -# WORKDIR for packages distributed that way. For EAPIs without
58 -# src_prepare, call elisp_src_prepare.
59 +# WORKDIR for packages distributed that way.
60
61 elisp_src_unpack() {
62 [[ -n ${A} ]] && unpack ${A}
63 @@ -112,11 +107,6 @@ elisp_src_unpack() {
64 mv ${P}.el ${PN}.el || die
65 [[ -d ${S} ]] || S=${WORKDIR}
66 fi
67 -
68 - case ${EAPI:-0} in
69 - 0|1) [[ -d ${S} ]] && cd "${S}"
70 - elisp_src_prepare ;;
71 - esac
72 }
73
74 # @FUNCTION: elisp_src_prepare
75 @@ -136,15 +126,15 @@ elisp_src_prepare() {
76 else
77 die "Cannot find ${patch}"
78 fi
79 - case ${EAPI:-0} in
80 - 0|1|2|3|4|5) epatch "${file}" ;;
81 + case ${EAPI} in
82 + 4|5) epatch "${file}" ;;
83 *) eapply "${file}" ;;
84 esac
85 done
86
87 # apply any user patches
88 - case ${EAPI:-0} in
89 - 0|1|2|3|4|5) epatch_user ;;
90 + case ${EAPI} in
91 + 4|5) epatch_user ;;
92 *) eapply_user ;;
93 esac
94
95 --
96 2.22.0

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies