1 |
On Friday 01 July 2005 16:56, Aron Griffis wrote: |
2 |
> Dan Armak wrote: [Fri Jul 01 2005, 03:42:22AM EDT] |
3 |
> |
4 |
> > ...OK, so deprange() needs to signal errors out-of-band. Like setting a |
5 |
> > KM_ERROR variable which causes the eclass to abort later on. |
6 |
> |
7 |
> Heh, doesn't work for the same reason you can't exit. It's |
8 |
> a subshell. |
9 |
> |
10 |
> How about this? |
11 |
> |
12 |
> ebuild: |
13 |
> DEPEND="some stuff" |
14 |
> qt_min_dep "3.3" |
15 |
> |
16 |
> eclass: |
17 |
> qt_min_dep() { |
18 |
> if cool; then |
19 |
> DEPEND="${DEPEND} new stuff" |
20 |
> else |
21 |
> die "..." |
22 |
> fi |
23 |
> } |
24 |
> |
25 |
Would work, but be against the general move to make the general ebuild section |
26 |
purely declarative :-( I don't want to change a great deal of code merely to |
27 |
catch incorrectly written ebuilds, when we can already print messages on |
28 |
stderr. |
29 |
|
30 |
I'd rather signal failure to code outside the subshell by touching a file in |
31 |
$T. |
32 |
|
33 |
-- |
34 |
Dan Armak |
35 |
Gentoo Linux developer (KDE) |
36 |
Public GPG key: http://dev.gentoo.org/~danarmak/danarmak-gpg-public.key |
37 |
Fingerprint: DD70 DBF9 E3D4 6CB9 2FDD 0069 508D 9143 8D5F 8951 |