Gentoo Archives: gentoo-dev

From: Donnie Berkholz <dberkholz@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Re: perl-module.eclass -- review
Date: Mon, 02 Mar 2009 17:51:09
Message-Id: 20090302175107.GD5295@comet
In Reply to: [gentoo-dev] Re: perl-module.eclass -- review by Torsten Veller
1 On 13:08 Mon 02 Mar , Torsten Veller wrote:
2 > Currently the eclass doesn't set any dependencies. If it is used the
3 > ebuild has to depend on perl if needed.
4 >
5 >
6 > I see the following options:
7 >
8 > 1) Don't add DEPEND to the eclass.
9 > So if a package is used for stage-building we have to raise EAPI and
10 > depend on dev-lang/perl[-build] in the ebuild.
11 >
12 > The part I don't understand in the bug above is:
13 > Does adding dev-lang/perl[-build] automagically reinstall
14 > perl during stage-building
15 > (here portage stops and complains).
16 >
17 >
18 > 2) Add DEPEND conditionally to the eclass.
19 > To give ebuilds the chance to inherit perl-module.eclass
20 > (and currently also perl-app.eclass) and support perl conditionally,
21 > we have to add another global variable to check it.
22 >
23 > (Checking CATEGORY and perl? probably could be added additonally)
24 >
25 >
26 > 3) Add DEPEND.
27 > Always depend on dev-lang/perl and
28 > if EAPI=2 then depend on dev-lang/perl[-build]
29 >
30 >
31 > Comments?
32
33 Having not spent a lot of time thinking about this, I'm guessing the use
34 case of concern is packages that have an optional perl module always
35 pulling in dev-lang/perl. This would apparently be relevant on an
36 embedded system that lacked perl but required a package with an optional
37 perl module. To handle that miniscule use case, I'd tend to go with a
38 conditional variable (GENTOO_PERL="no"?) that defaults to "yes".
39
40 --
41 Thanks,
42 Donnie
43
44 Donnie Berkholz
45 Developer, Gentoo Linux
46 Blog: http://dberkholz.wordpress.com

Replies

Subject Author
Re: [gentoo-dev] Re: perl-module.eclass -- review "Robin H. Johnson" <robbat2@g.o>