Gentoo Archives: gentoo-dev

From: William Hubbs <williamh@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH] skel.ebuild: Update comments for inherit, SLOT, KEYWORDS.
Date: Sun, 31 Dec 2017 19:26:37
Message-Id: 20171231192625.GA15103@linux1.home
In Reply to: Re: [gentoo-dev] [PATCH] skel.ebuild: Update comments for inherit, SLOT, KEYWORDS. by Pacho Ramos
1 On Sun, Dec 31, 2017 at 08:07:33PM +0100, Pacho Ramos wrote:
2 > El dom, 31-12-2017 a las 12:12 -0600, William Hubbs escribió:
3 > > On Sun, Dec 31, 2017 at 06:44:39PM +0100, Michał Górny wrote:
4 > > > W dniu nie, 31.12.2017 o godzinie 14∶31 +0100, użytkownik Ulrich Müller
5 > > > napisał:
6 > > > > epatch() is provided by epatch.eclass now. Also comment the inherit
7 > > > > line, since not every ebuild will use it.
8 > > > >
9 > > > > Empty SLOT doesn't disable slots, but is outright illegal in all EAPIs.
10 > > > > Similar for KEYWORDS="*", which isn't "deprecated" but invalid.
11 > > > > ---
12 > > > > skel.ebuild | 9 ++++-----
13 > > > > 1 file changed, 4 insertions(+), 5 deletions(-)
14 > > > >
15 > > > > diff --git a/skel.ebuild b/skel.ebuild
16 > > > > index 7ac9dfb7d6d8..4c19b1de4cb8 100644
17 > > > > --- a/skel.ebuild
18 > > > > +++ b/skel.ebuild
19 > > > > @@ -13,9 +13,9 @@
20 > > > > EAPI=6
21 > > > >
22 > > > > # inherit lists eclasses to inherit functions from. For example, an
23 > > > > ebuild
24 > > > > -# that needs the epatch function from eutils.eclass won't work without
25 > > > > the
26 > > > > +# that needs the epatch function from epatch.eclass won't work without
27 > > > > the
28 > > > > # following line:
29 > > > > -inherit eutils
30 > > > > +#inherit epatch
31 > > >
32 > > > Well, given that it's EAPI 6 and we do not want to encourage people to
33 > > > use epatch there, I would prefer if we replaced that example with
34 > > > something else. But it's just a wishful thinking here.
35 > >
36 > > +1, but I'm not going to suggest what to replace it with.
37 > >
38 > > William
39 >
40 > Why not eapply (and drop inherit then)? :/
41
42 Because that isn't the preferred way to apply patches since it requires
43 you to override src_prepare.
44
45 If the example was about how to apply patches, the correct way is to put
46 them in a PATCHES variable in global scope, but that's not the intent of
47 the example.
48
49 The intent is to show inheriting an eclass.
50
51 William

Attachments

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