1 |
On 04/27/2012 06:49 AM, Ulrich Mueller wrote: |
2 |
>>>>>> On Fri, 27 Apr 2012, Chí-Thanh Christopher Nguyễn wrote: |
3 |
> |
4 |
>> Ciaran McCreesh schrieb: |
5 |
>>>> * two new files in profile directories supported, |
6 |
>>>> package.use.stable.mask and package.use.stable.force |
7 |
>>>> * syntax is identical to package.use.mask and package.use.force |
8 |
>>>> * meaning is identical to package.use.mask and package.use.force, |
9 |
>>>> except that the resulting rules are ONLY applied iff a stable keyword |
10 |
>>>> is in use |
11 |
>>> This means that an ebuild will effectively change when moved from |
12 |
>>> ~arch to arch. The point of ~arch is to test ebuilds before they're |
13 |
>>> moved to arch. |
14 |
> |
15 |
>> I agree that the ~arch ebuilds should be tested in the same |
16 |
>> configuration in which they will end up in arch. However in this |
17 |
>> case, the possible configurations for arch are a subset of those in |
18 |
>> ~arch, so the testing covers those too. |
19 |
> |
20 |
> Maybe I'm missing something, but what would happen when the newest |
21 |
> version of a package is marked stable? The masked USE flags would |
22 |
> become unavailable for everyone? |
23 |
|
24 |
In order to be practical, I guess we'd have to add a constraint which |
25 |
says that if KEYWORDS contains the stable variant of a particular |
26 |
keyword, then it should also be considered to implicitly contain the |
27 |
unstable variant when the package manager is deciding whether or not to |
28 |
apply package.use.{mask,force}. |
29 |
|
30 |
So, here's a description of the whole algorithm that I'd use: |
31 |
|
32 |
1) Let EFFECTIVE_KEYWORDS equal the set of values contained in KEYWORDS, |
33 |
plus ** and all the unstable variants of the stable values contained in |
34 |
KEYWORDS. For example: |
35 |
|
36 |
KEYWORDS="~amd64 x86" -> EFFECTIVE_KEYWORDS="~amd64 x86 ** ~x86" |
37 |
|
38 |
2) Intersect EFFECTIVE_KEYWORDS with effective ACCEPT_KEYWORDS, where |
39 |
effective ACCEPT_KEYWORDS includes any relevant values from |
40 |
package.accept_keywords. For example, here is a table of intersections |
41 |
of EFFECTIVE_KEYWORDS="~amd64 x86 ** ~x86" with various effective |
42 |
ACCEPT_KEYWORDS values: |
43 |
|
44 |
ACCEPT_KEYWORDS | INTERSECTION | package.stable |
45 |
----------------------------------------------------- |
46 |
x86 | x86 | yes |
47 |
x86 ~x86 | x86 ~x86 | no |
48 |
** | ** | no |
49 |
amd64 ~amd64 | ~amd64 | no |
50 |
|
51 |
3) Apply package.stable settings if INTERSECTION contains only stable |
52 |
keywords. For example, see the package.stable column in the table above. |
53 |
-- |
54 |
Thanks, |
55 |
Zac |