Gentoo Archives: gentoo-dev

From: Duncan <1i5t5.duncan@×××.net>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Re: Change USE flags when compiling with FEATURES=test
Date: Sun, 18 Mar 2012 07:19:28
In Reply to: Re: [gentoo-dev] Change USE flags when compiling with FEATURES=test by Kent Fredric
1 Kent Fredric posted on Sun, 18 Mar 2012 08:43:55 +1300 as excerpted:
3 > I think what would be more practical is a sane way to enable FEATURES=""
4 > on a per-package level like USE flags in portage, then you could enable
5 > FEATURES="test" for that one package and it would always build that
6 > package with USE="test"
7 >
8 > Paludis does this already via an extended use.conf syntax:
10 > Perhaps portage does this already and I'm hiding under a rock, but I
11 > haven't seen it
13 What's you're definition of "sane"? Does it include the
14 /etc/portage/package.env and/or /etc/portage/env/cat-egory/pkg files
15 configuration options?
17 I've been using (and prefer) the latter for quite some time for various
18 per-package settings (tho not the particular one in question here)
19 without an issue. The former is newer but somewhat more limited, to
20 make.conf style direct variable assignments, while the latter allows full
21 bash flexibility, which I take advantage of.
23 For example, the following /etc/portage/env/media-video/smplayer-0.6.9-r1
24 allowed me to avoid editing the ebuild directly. (IIRC it was a patch
25 necessary to build the package with gcc-4.6. I'm on smplayer-0.7.1 now,
26 but the version-specific package-path limited deployment to just that one
27 version.)
29 post_src_prepare () {
30 sed -i '1i#define OF(x) x' src/findsubtitles/quazip/*.h
31 }
34 See the /etc/portage/package.env and /etc/portage/env/ sections of the
35 portage (5) manpage for the details.
37 So... Does that fit your definition of "sane"? =:^)
39 --
40 Duncan - List replies preferred. No HTML msgs.
41 "Every nonfree program has a lord, a master --
42 and if you use the program, he is your master." Richard Stallman