Gentoo Archives: gentoo-dev

From: Samuli Suominen <ssuominen@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] ebuild laziness and binpkg overhead
Date: Wed, 20 Jun 2012 04:24:05
Message-Id: 4FE14F13.7080105@gentoo.org
In Reply to: Re: [gentoo-dev] ebuild laziness and binpkg overhead by Doug Goldstein
1 On 06/20/2012 06:46 AM, Doug Goldstein wrote:
2 > On Tue, Jun 19, 2012 at 10:27 PM, Samuli Suominen <ssuominen@g.o> wrote:
3 >> On 06/20/2012 06:19 AM, Mike Frysinger wrote:
4 >>>
5 >>> On Tuesday 19 June 2012 22:46:26 Samuli Suominen wrote:
6 >>>>
7 >>>> On 06/15/2012 06:10 PM, Mike Frysinger wrote:
8 >>>>>
9 >>>>> On Friday 15 June 2012 03:44:14 Samuli Suominen wrote:
10 >>>>>>
11 >>>>>> On 06/13/2012 06:02 AM, Mike Frysinger wrote:
12 >>>>>>>
13 >>>>>>> i've noticed a growing trend where people put setup of variables into
14 >>>>>>> pkg_setup that only matter to src_* funcs presumably so they don't
15 >>>>>>> have
16 >>>>>>> to call the respective src_* func from an inherited eclass.
17 >>>>>>> unfortunately this adds pointless overhead to binpkgs. can we please
18 >>>>>>> move away from this practice ?
19 >>>>>>
20 >>>>>>
21 >>>>>> Every Xfce ebuild in gentoo-x86 is using pkg_setup() for 3 variables,
22 >>>>>> DOCS for src_install, PATCHES for src_prepare
23 >>>>>
24 >>>>>
25 >>>>> these are static variables, so defining them in a func is pointless
26 >>>>
27 >>>>
28 >>>> "sort of" not necessarily, 'has $useflag && PATCHES+=( )' has been used
29 >>>> before, not sure if it's used in tree right now or not
30 >>>
31 >>>
32 >>> as we've always said, USE conditional patches are to be highly discouraged
33 >>
34 >>
35 >> I agree BUT there are cases where it's OK to use conditional patching:
36 >>
37 >> For example, libfoo-0.1.1 is broken and is fixed in git for master which
38 >> will be in next release. The fix doesn't apply to 0.1.1 cleanly without
39 >> heavy modifications.
40 >> Then you would take the easiest possible route to get 0.1.1 working again,
41 >> with the comfort of knowing it's properly fixed for the next version.
42 >>
43 >> -Samuli
44 >>
45 >
46 > I assume you mean libfoo-0.1.1 is broken when USE=bar is enabled and
47 > you get a patch for that conditional case when USE=bar is enabled.
48
49 Right. Of course.
50
51 > Either way, the better solution is to mask it and have people use libfoo-0.1.0
52 >
53
54 Doesn't really apply to this case:
55 Think about masking stable Xfce 4.10 when the fix is in git that will be
56 released as 4.12 in about year. ;-)
57
58 - Samuli