Gentoo Archives: gentoo-dev

From: Ben de Groot <yngwin@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [RFC] Ability to pass arguments to src_configure/src_compile
Date: Sat, 06 Sep 2008 20:11:18
Message-Id: 48C2E3C5.5040701@gentoo.org
In Reply to: Re: [gentoo-dev] [RFC] Ability to pass arguments to src_configure/src_compile by Alec Warner
1 Alec Warner wrote:
2 > On Sat, Sep 6, 2008 at 10:36 AM, Thomas Anderson <gentoofan23@g.o> wrote:
3 >> Hi,
4 >> Currently we have a lot of:
5 >> src_configure() {
6 >> econf $(use_enable dvdr) \
7 >> $(use_with ipv6 ssl) \
8 >> --with-system-zlib
9 >> }
10 >>
11 >> Introducing(Idea shamelessly taken from Exherbo):
12 >> DEFAULT_SRC_CONFIGURE_USE_{WITHS,ENABLES}
13 >> DEFAULT_SRc_CONFIGURE_EXTRA_PARAMS
14 >>
15 >> The code from above could be rewritten like so:
16 >>
17 >> DEFAULT_SRC_CONFIGURE_USE_ENABLES=( 'dvdr' )
18 >> DEFAULT_SRC_CONFIGURE_USE_WITHS=( 'ipv6 ssl' )
19 >> DEFAULT_SRC_CONFIGURE_EXTRA_PARAMS=( '--with-system-zlib' )
20 >>
21 >> That's much simpler.
22 >
23 > It saves you 1 line and reduces readability and intuitiveness by a
24 > fair margin; how is it simpler?
25
26 It may be 2 lines less, but it is 42 characters more.
27 Plus, I dislike caps. :-p

Attachments

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

Replies

Subject Author
Re: [gentoo-dev] [RFC] Ability to pass arguments to src_configure/src_compile "Santiago M. Mola" <coldwind@g.o>
[gentoo-dev] Re: [RFC] Ability to pass arguments to src_configure/src_compile Steve Long <slong@××××××××××××××××××.uk>