Gentoo Archives: gentoo-dev

From: Alec Warner <antarus@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] GNU userland and binary package (WAS: RFC: sh versionator.eclass)
Date: Thu, 11 Oct 2007 03:16:12
Message-Id: b41005390710102003y489b3351oab31c14fee87c681@mail.gmail.com
In Reply to: Re: [gentoo-dev] GNU userland and binary package (WAS: RFC: sh versionator.eclass) by Natanael Copa
1 On 10/8/07, Natanael Copa <natanael.copa@×××××.com> wrote:
2 > On Mon, 2007-10-08 at 06:52 -0700, Alec Warner wrote:
3 > > On 10/8/07, Natanael Copa <natanael.copa@×××××.com> wrote:
4 > > > On Sun, 2007-10-07 at 21:26 -0600, Joe Peterson wrote:
5 > > > > Mike Frysinger wrote:
6 > > > > > Fabian has summed it up nicely, thanks. i could care less what your userland
7 > > > > > is outside of the ebuild environment since it doesnt matter to ebuild
8 > > > > > writers. you want a deficient runtime environment, more power to you, but
9 > > > > > forcing that environment onto ebuild developers is not acceptable. off the
10 > > > > > top of my head, i'd like to see GNU find/xargs added to the ebuild
11 > > > > > environment.
12 > > > > > -mike
13 > > > >
14 > > > > Mike, exactly as I said. That's option #2, and I think it could be a
15 > > > > great solution. As for deficient, well, that's in the eye of the
16 > > > > beholder. ;)
17 > > > >
18 > > > > -Joe
19 > > >
20 > > > Question, if you go for #2. Does that mean you will need all the
21 > > > required GNU userland to do binary only installs?
22 > > >
23 > > > It would be highly desireable to be able to do binary installs (write
24 > > > your own binary only package manager) without depending on all the GNU
25 > > > stuff needed to compile the packages.
26 > >
27 > > Your own binary only package manager would still need to provide
28 > > Option #2; ie you need to have GNU tools installed to process the
29 > > binary packages. pkg_* functions could still have GNU stuff in them
30 > > and those still get run during a binary package install.
31 >
32 > If we would like to be able to do binary installs without the GNU tools,
33 > what alternatives do we have?
34 >
35 > Those pops up to my mind:
36 >
37 > A. move the pkg_* functions out of the ebuild to a separate file. Those
38 > have a subset of the EAPI and needs to be posix compliant.
39
40 This is just rife with complications, IMHO. Two files per ebuild
41 revision? Shared pre/post functions? Extra manifests, stats,
42 sourcing, bigger tree, inode requirements. Probably not an easy sell
43 here.
44
45 >
46 > B. don't use GNU extensions in pkg_functions and have some way to export
47 > them (extract pkg_* functions from environment.bz2). Those can then be
48 > used by pre/post script in binary package manager.
49
50 This is your best bet, but again mandates are ineffective. As you've
51 no doubt noticed with quoting, people will do whatever works and the
52 people who aim for odd targets like no GNU crap or sh compatability
53 are going to have to do the code reviews and encourage that sort of
54 thing. Just saying 'pre/post functions must be POSIX compatable' will
55 get you nowhere. The point here is to sell your idea to other
56 developers; if you can't sell it you may need to take it elsewhere.
57
58 >
59 > C. Binary package managers will need to write their own pre/post
60 > scripts
61
62 Good luck with this route; you may be able to write replacements for
63 most utilities but I bet the conversion would still fail on weird
64 constructs.
65
66 D. Keep your own ebuilds. Particularly for embedded you probably
67 aren't using a ton of them anyway and given a sufficient pool of
68 developers interested in POSIX compatible ebuilds you could probably
69 hammer out a posix-compliant embedded tree in short order. I know
70 everyone hates option D; but I'm also kind of irritated by everyone
71 trying to push weird requirements on everyone else. If you can't
72 convince the majority of developers to do thing X, you may end up
73 having to do it yourself; welcome to open source software ;)
74
75 -Alec
76 --
77 gentoo-dev@g.o mailing list

Replies