Gentoo Archives: gentoo-dev

From: Erik Grinaker <erikg@××××××××××××××.net>
To: gentoo-dev@g.o
Subject: Re: [gentoo-dev] ebuild USE priority
Date: Wed, 15 May 2002 06:00:50
Message-Id: 1021459908.4468.5.camel@maas.wired
In Reply to: Re: [gentoo-dev] ebuild USE priority by Matthew Kennedy
1 On Wed, 2002-05-15 at 06:55, Matthew Kennedy wrote:
2
3 > On Tue, 2002-05-14 at 17:23, Erik Grinaker wrote:
4 > > The ebuild is for the Unix Amiga Emulator, or uae for short. uae allows
5 > > you to select which backend to compile against during ./configure, and
6 > > you can choose *either* x, svgalib, ncurses or sdl.
7 >
8 > When creating the xemacs-gamma ebuild I encountered the same dillema.
9 > When you say "*either*", I assume you mean that X, svga, ncurse and sdl
10 > are optional, but mutually exclusive.
11
12 Yep, that's right.
13
14
15 > > If a user has, say, both X and svga in his USE variable, how do I
16 > > determine whether to use X or svgalib for backend?
17 >
18 > XEmacs gamma supports gtk OR motif OR lucid interfaces (each of which
19 > can be considered a use flag) in mutual exclusion. Of course, I don't
20 > want to dictate one of those three to the user, since my preference may
21 > not be theirs.
22 >
23 > I thought of a priority scheme, but couldn't see clearly how that would
24 > be done. How did you do it, BTW?
25
26 Well, I haven't completed the ebuild yet, but I decided to go for my own
27 priorities ;
28
29 use ncurses && backend="--with-asciiart"
30 use svga && backend="--with-svgalib"
31 use sdl && backend="--with-sdl --with-sdl-sound --with-sdl-gfx"
32 use X && backend="--with-x"
33
34 These are set in reverse so that the last one that matches will be
35 active. But I'm really not satisfied with this, because if a user would
36 like to have, as you say later in your mail, an svga emulator while
37 having both x and svga in his USE then his only option would be to
38 manually change USE before emerging.
39
40
41 > What I ended up doing was checking for an env. var. named USE_PREF which
42 > is localized to xemacs-gamma. It allows the user to merge xemacs-gamma
43 > like this:
44 >
45 > USE_PREF=gtk app-editors/xemacs-gamma
46
47 This seems to be quite sensible, even though it creates it's share of
48 troubles when checking DEPENDs. Does any of the Gentoo developers have
49 any thoughts on this?
50
51
52 --
53
54 Erik Grinaker
55 Freelance UNIX/Linux systems consultant
56
57 "Perfection is acheived not when there is nothing more to add, but
58 rather when there is nothing more to take away"
59 - Antoine de Saint-Exupéry

Attachments

File name MIME type
signature.asc application/pgp-signature