1 |
On 08/14/2012 02:44 AM, Michał Górny wrote: |
2 |
> Hello, |
3 |
> |
4 |
> As some of you may have noticed, lately introduced 'double include |
5 |
> preventions' have caused changes in effective phase functions in a few |
6 |
> ebuilds. |
7 |
|
8 |
Can't that be avoided by putting the EXPORT_FUNCTIONS call outside of |
9 |
the ifndef block? The function implementations themselves can be inside |
10 |
the ifndef block, since that only need to be sourced once. |
11 |
|
12 |
> Also, often it is undesirable that change in inherits of |
13 |
> an eclass may cause an undesired change of exported functions. To solve |
14 |
> these problems, we are proposing the following: |
15 |
> |
16 |
> |
17 |
> 1. If an ebuild does not provide an explicit phase function, the phase |
18 |
> functions *directly exported* by *directly inherited* eclasses are used |
19 |
> to find a suitable default, |
20 |
> |
21 |
> 2. Thus, if an eclass inherits another eclass and expects the phase |
22 |
> functions of that eclass to be effective to the ebuild, it needs to |
23 |
> create its own phase function and export it. |
24 |
> |
25 |
> |
26 |
> This should make the ebuild behavior simpler to understand and saner. |
27 |
> It should also fix the forementioned issues, and allow us to make |
28 |
> the 'source eclasses only once'[1] proposal simpler. |
29 |
> |
30 |
> [1]:https://bugs.gentoo.org/show_bug.cgi?id=422533 |
31 |
|
32 |
I'm not sure that your cure isn't worse than the disease. |
33 |
-- |
34 |
Thanks, |
35 |
Zac |