1 |
>>>>> On Tue, 30 May 2017, Alexis Ballier wrote: |
2 |
|
3 |
> The way I see it, this boils down to spec'ing something that |
4 |
> guarantees there's a unique solution given an input. The solution |
5 |
> does not have to be good or bad (we don't have a good metric on that |
6 |
> anyway), it just has to be deterministic so that developers can |
7 |
> arrange their REQUIRED_USE constraints to have PM chose the proper |
8 |
> solution. |
9 |
|
10 |
Right. As I see it, the problem we must solve is that for k USE flags |
11 |
there are 2**k possible combinations, but there may be only n |
12 |
combinations that are valid, with n < 2**k. For example, for |
13 |
IUSE="foo bar baz" there are 2**3 = 8 possible combinations, but with |
14 |
REQUIRED_USE="|| ( foo bar baz )" or "^^ ( foo bar baz )" only 7 or 3 |
15 |
of them are valid, respectively. |
16 |
|
17 |
Now we can either just specify which of the combinations are valid; |
18 |
this is what REQUIRED_USE currently does. Or we can specify a complete |
19 |
mapping from every invalid input combination of flags to a valid |
20 |
output combination. I think we should do the latter. |
21 |
|
22 |
Ulrich |