Gentoo Archives: gentoo-dev

From: Mike Frysinger <vapier@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] huse: new helper for low level eclass writers
Date: Wed, 19 Oct 2011 19:27:08
Message-Id: 201110191526.22113.vapier@gentoo.org
In Reply to: Re: [gentoo-dev] huse: new helper for low level eclass writers by Brian Harring
1 On Wednesday 19 October 2011 14:53:07 Brian Harring wrote:
2 > On Wed, Oct 19, 2011 at 02:05:50PM -0400, Mike Frysinger wrote:
3 > > i wrote a new func for toolchain.eclass: huse. this is because the
4 > > toolchain.eclass supports multiple versions in parallel, and the IUSE
5 > > value can vary greatly between them. so doing `use foo` without
6 > > checking IUSE first doesn't work. since i got a request to use this in
7 > > other eclasses (for the same reason), i figured i'd move it to
8 > > eutils.eclass so more people can benefit.
9 > >
10 > > now that we have "in_iuse" in eutils.eclass (with all the caveats), i'll
11 > > be
12 > >
13 > > adding huse:
14 > > huse() {
15 > >
16 > > in_iuse $1 || return 1
17 > > use $1
18 > >
19 > > }
20 > >
21 > > any comments before i publish ?
22 >
23 > Call it safe_use.
24
25 safe for who ? that implies to me much more vagueness than "iuse" ...
26 -mike

Attachments

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

Replies

Subject Author
Re: [gentoo-dev] huse: new helper for low level eclass writers Brian Harring <ferringb@×××××.com>