1 |
Ciaran McCreesh <ciaran.mccreesh@××××××××××.com> posted |
2 |
20080908231325.0846cead@snowmobile, excerpted below, on Mon, 08 Sep 2008 |
3 |
23:13:25 +0100: |
4 |
|
5 |
> On Mon, 8 Sep 2008 14:33:50 -0700 |
6 |
> Donnie Berkholz <dberkholz@g.o> wrote: |
7 |
>> |
8 |
>> One of the great things about ebuilds is that they're very natural to |
9 |
>> write in most cases, if you can manage to build the program by hand. |
10 |
>> Raising this barrier of entry for questionable benefit seems like a bad |
11 |
>> idea. We don't need to make it any harder to begin contributing to |
12 |
>> Gentoo. |
13 |
|
14 |
Great point, Donnie. One of the things I've appreciated about the ebuild |
15 |
format is how accessible it is... in comparison to say some spec file. |
16 |
Part of that of course is that it's right out there in the open, not tied |
17 |
up in some semi-transparent tarball, but part of it is certainly that |
18 |
it's reasonably close to simple bash, as well. |
19 |
|
20 |
> So why are we making people know the exact ins and outs of |
21 |
> reimplementing default functions, complete with knowledge of whether or |
22 |
> not to use die, when all they need in most cases is to set a simple |
23 |
> variable instead? |
24 |
> |
25 |
> What proportion of people do you think know whether or not you need a |
26 |
> die with econf or emake? |
27 |
|
28 |
This is a valid point as well. However, for a user simply concerned with |
29 |
getting a functional ebuild so the package is tracked by the PM as |
30 |
opposed to not (or manually tracking with package.provided), an extra die |
31 |
or two, or even the lack thereof, and the docs and stuff, don't matter as |
32 |
much as something easily understood and written with little more than |
33 |
knowledge of bash and what's easily cribbed from a few existing ebuilds |
34 |
used as samples. |
35 |
|
36 |
These rather arbitrary vars do make sense to someone with a bit more |
37 |
knowledge, but are going to be about as opaque as the proper use of die, |
38 |
etc. What's worse, they make the simple-case ebuilds more difficult to |
39 |
crib from for the user-sysadmin simply interested in getting a functional |
40 |
ebuild that allows the packaging system knowledge of what he's |
41 |
installing. This sort of person is likely to write the ebuild, test it, |
42 |
and when it works, be done with it, regardless of its "correctness", and |
43 |
ideally with as little pre-supposed knowledge as possible. They don't |
44 |
care about dies, but will care if they have to spend another half hour |
45 |
diving into docs to figure out how to effectively translate |
46 |
the .configure --with/etc stuff into the appropriate vars. |
47 |
|
48 |
> The DEFAULT_* variables make it *easier* to write packages because half |
49 |
> the time you don't need to arse around writing src_* functions. Every |
50 |
> src_* function written by someone is another place there can be a |
51 |
> non-obvious screwup. |
52 |
|
53 |
That's true for the dev, certainly, but they do presuppose certain |
54 |
additional pre-knowledge that our user-sysadmin above won't have |
55 |
immediately. |
56 |
|
57 |
What's more worrying from the perspective of that person is that while |
58 |
all these new vars are optional, if devs (with that pre-knowledge) start |
59 |
using them as easier, pretty soon that person above isn't going to have |
60 |
any easily accessible simple ebuilds to crib from any more. It's not |
61 |
directly apparent that those vars hold what would be fed to .configure |
62 |
more or less directly, without knowledge of the package the ebuild is |
63 |
for. In ordered to get that knowledge, the newbie ebuild writer will be |
64 |
forced to either investigate the packages he's cribbing from the ebuilds |
65 |
of, or look up the PM/PMS/ebuild documentation. |
66 |
|
67 |
At least with eclasses, once one knows about inherit (a pretty simple |
68 |
concept once people start looking at ebuilds), it's standard bash |
69 |
functionality and easy enough to lookup what those arbitrary vars |
70 |
actually do. If we implement this, it's going to be locked away in the |
71 |
PM somewhere not so easily accessible. Additional specialized knowledge |
72 |
will be necessary. |
73 |
|
74 |
(Hmm... this argument went other than I intended. I was planning to |
75 |
point out that usage of the vars was optional, and that our user-sysadmin |
76 |
wouldn't have to use them if they didn't want to... but then as I wrote, |
77 |
I realized it may be optional, but that doesn't help much if all the |
78 |
simple ebuilds he finds to crib from end up using the pre-knowledge |
79 |
required vars, leaving him nothing simple to crib from without that |
80 |
knowledge. The accessibility level will have been reduced if this |
81 |
happens.) |
82 |
|
83 |
-- |
84 |
Duncan - List replies preferred. No HTML msgs. |
85 |
"Every nonfree program has a lord, a master -- |
86 |
and if you use the program, he is your master." Richard Stallman |