1 |
On Tue, Aug 08, 2006 at 07:23:31AM +0100, Ciaran McCreesh wrote: |
2 |
> On Mon, 7 Aug 2006 21:41:39 -0700 Brian Harring <ferringb@×××××.com> |
3 |
> wrote: |
4 |
> | > The use.force feature is complementary to use.mask. It's exactly |
5 |
> | > the same concept, but inverted. |
6 |
> | |
7 |
> | And both files _should_ be implemented via use deps. |
8 |
> |
9 |
> Huh? How? |
10 |
|
11 |
forcing cxx on via package.mask for gcc |
12 |
sys-devel/gcc[-cxx] |
13 |
|
14 |
forcing it off |
15 |
sys-devel/gcc[cxx] |
16 |
|
17 |
Pretty simple. |
18 |
|
19 |
*Full* implementation of use deps requires ability to flip on use |
20 |
flags as needed (whether to break soft cycles, or just implemented |
21 |
such that use deps force what they need), and requires *tracking* of |
22 |
the history of the toggling so that a |
23 |
|
24 |
DEPEND="sys-devel/gcc[cxx] sys-devel/gcc[-cxx]" |
25 |
|
26 |
results in unsolvable; granted, it's a contrived example, but in a |
27 |
large graph it *will* occur. |
28 |
|
29 |
Getting it right is hard, but it's a requirement for any |
30 |
implementation that intends a nonsucky resolver- 'soft' (breakable) |
31 |
cycles exist already (unixodbc and qt is the classic example), the |
32 |
number of soft cycles will grow once use deps are available. |
33 |
|
34 |
So... to be able to handle use deps fully, you have to track the |
35 |
flipping of it; to discern if a pkg is even usable, you have to pass |
36 |
it through the mask/unmask, which can do the 'imprinting' up front. |
37 |
|
38 |
Using package.{un,}mask for use.force/package.use.mask doesn't |
39 |
actually require *fully* supporting use deps though; portage already |
40 |
supports it in a limited fashion via package.use and the |
41 |
package.use.mask patch zac stuffed in the other day. |
42 |
|
43 |
Pretty much all it requires is just mangling his patches slightly so |
44 |
if it's a use atom, it gets shifted out into the new dicts he's trying |
45 |
to add to config. |
46 |
|
47 |
Goes without saying there is a delay for support on this for (yet |
48 |
another) mangling of portage profile support to protect itself. |
49 |
|
50 |
~harring |