Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Cc: "Ulrich Müller" <ulm@g.o>
Subject: Re: [gentoo-dev] [PATCH 7/8] git-r3.eclass: Support EAPI 8, drop support for EAPI 4
Date: Mon, 21 Jun 2021 17:25:39
Message-Id: 404549a1c40e43b08a1c5952e4d372e5ae654716.camel@gentoo.org
In Reply to: [gentoo-dev] [PATCH 7/8] git-r3.eclass: Support EAPI 8, drop support for EAPI 4 by "Ulrich Müller"
1 On Mon, 2021-06-21 at 18:49 +0200, Ulrich Müller wrote:
2 > Signed-off-by: Ulrich Müller <ulm@g.o>
3 > ---
4 > eclass/git-r3.eclass | 18 ++++++------------
5 > 1 file changed, 6 insertions(+), 12 deletions(-)
6 >
7 > diff --git a/eclass/git-r3.eclass b/eclass/git-r3.eclass
8 > index 9c4f2c9d778e..365f21a4ed4c 100644
9 > --- a/eclass/git-r3.eclass
10 > +++ b/eclass/git-r3.eclass
11 > @@ -4,21 +4,15 @@
12 > # @ECLASS: git-r3.eclass
13 > # @MAINTAINER:
14 > # Michał Górny <mgorny@g.o>
15 > -# @SUPPORTED_EAPIS: 4 5 6 7
16 > +# @SUPPORTED_EAPIS: 5 6 7 8
17 > # @BLURB: Eclass for fetching and unpacking git repositories.
18 > # @DESCRIPTION:
19 > # Third generation eclass for easing maintenance of live ebuilds using
20 > # git as remote repository.
21 >
22 > -case "${EAPI:-0}" in
23 > - 0|1|2|3)
24 > - die "Unsupported EAPI=${EAPI} (obsolete) for ${ECLASS}"
25 > - ;;
26 > - 4|5|6|7)
27 > - ;;
28 > - *)
29 > - die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}"
30 > - ;;
31 > +case ${EAPI:-0} in
32 > + 5|6|7|8) ;;
33 > + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
34 > esac
35 >
36 > EXPORT_FUNCTIONS src_unpack
37 > @@ -28,7 +22,7 @@ if [[ ! ${_GIT_R3} ]]; then
38 > PROPERTIES+=" live"
39 >
40 > if [[ ! ${_INHERITED_BY_GIT_2} ]]; then
41 > - if [[ ${EAPI:-0} != [0123456] ]]; then
42 > + if [[ ${EAPI} != [56] ]]; then
43 > BDEPEND=">=dev-vcs/git-1.8.2.1[curl]"
44 > else
45 > DEPEND=">=dev-vcs/git-1.8.2.1[curl]"
46 > @@ -612,7 +606,7 @@ git-r3_fetch() {
47 > local commit_date=${4:-${EGIT_COMMIT_DATE}}
48 >
49 > # support new override API for EAPI 6+
50 > - if ! has "${EAPI:-0}" 0 1 2 3 4 5; then
51 > + if [[ ${EAPI} != 5 ]]; then
52 > # get the name and do some more processing:
53 > # 1) kill .git suffix,
54 > # 2) underscore (remaining) non-variable characters,
55
56 LGTM, for both git-r3 patches.
57
58 --
59 Best regards,
60 Michał Górny