1 |
I decided to try something a little different because I had some ideas |
2 |
for improving the existing EAPI patches I've seen going into other |
3 |
eclasses. So here is my patch for x-modular.eclass. I tested it with |
4 |
ebuilds using EAPIs 0, 1, and 2, and it appeared to work fine. It |
5 |
already happened to have a function called src_configure, so that |
6 |
doesn't appear in the patch. |
7 |
|
8 |
One thing I see as an improvement is a lack of EAPI value checks |
9 |
throughout the ebuild to avoid repetition between the function export |
10 |
and the function call. Things just check whether a function was |
11 |
exported, which is the only place where EAPI value checks happen. |
12 |
|
13 |
Additionally, the fallback in case statements is "I don't know what to |
14 |
do" and supported EAPIs are explicitly defined. This will make it |
15 |
obvious when the eclass doesn't support a new EAPI instead of it |
16 |
randomly failing after you try it. |
17 |
|
18 |
Any thoughts? |
19 |
|
20 |
-- |
21 |
Thanks, |
22 |
Donnie |
23 |
|
24 |
Donnie Berkholz |
25 |
Developer, Gentoo Linux |
26 |
Blog: http://dberkholz.wordpress.com |