1 |
-----BEGIN PGP SIGNED MESSAGE----- |
2 |
Hash: SHA1 |
3 |
|
4 |
Pacho Ramos wrote: |
5 |
> El lun, 02-03-2009 a las 13:01 -0800, Zac Medico escribió: |
6 |
>> || ( ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) x11-libs/qt:4 ) |
7 |
>> |
8 |
>> It's a variation of bug 161953 [1]. For this particular variation, |
9 |
>> at the moment I don't think there's a good way to distinguish that |
10 |
>> the choice on the left is the better choice. |
11 |
> |
12 |
>>From my point of view, I think that portage should do something like |
13 |
> calculating how much a dep is already in the system, for example, in |
14 |
> this case, I have 50% of ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) |
15 |
> already installed on my system while 0% of x11-libs/qt:4. Then, |
16 |
> ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) would be a better option |
17 |
> because, hopefully, a user that has already installed a portion of this |
18 |
> dep, will prefer to maintain it installed |
19 |
> |
20 |
> But, this is only theoretical as I am not a programmer and I don't know |
21 |
> if this could be implemented |
22 |
|
23 |
You're right. It's easy to says it in words but if you tried to |
24 |
actually implementing you'd find that the PROPERTIES=virtual concept |
25 |
simplifies the problem a lot and makes it possible to optimally |
26 |
solve some cases of bug 141118 that couldn't otherwise be solved |
27 |
optimally without the information that PROPERTIES=virtual provides. |
28 |
|
29 |
What we're talking about is a cost calculation and in order for the |
30 |
cost calculation to be as accurate as possible, we need to know |
31 |
which ebuilds have zero-cost to install (the virtual ones do not |
32 |
install anything directly so they are considered to have zero-cost |
33 |
in themselves). If you consider all ebuilds to have equal cost then |
34 |
your calculation won't be as accurate as it could be. Knowing which |
35 |
ebuilds are virtual gives a hint to the resolver that it should |
36 |
perform a "lookahead" in the cost calculation. |
37 |
|
38 |
We could implement a similar lookahead mechanism for non-virtual |
39 |
ebuilds, but it's more useful for the virtual ones. Backtracking |
40 |
(which isn't implemented yet but is planned for bug 1343) would also |
41 |
be useful for implementing additional cost optimizations (like the |
42 |
one for bug 260225). |
43 |
- -- |
44 |
Thanks, |
45 |
Zac |
46 |
-----BEGIN PGP SIGNATURE----- |
47 |
Version: GnuPG v2.0.10 (GNU/Linux) |
48 |
|
49 |
iEYEARECAAYFAkmthAwACgkQ/ejvha5XGaP0WwCgkpqDyXQTKRbrBU9ncvfmOIoo |
50 |
UlwAoOmIu1RCt7/wfSgTrMDCCx8t6IcP |
51 |
=CVC5 |
52 |
-----END PGP SIGNATURE----- |