FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.

» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo Portage Developer

LinkBack Thread Tools
Old 03-03-2009, 06:25 PM
Zac Medico
Default emerge prefers to install x11-libs/qt:4 instead of ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) even when x11-libs/qt-gui:4 is already installed

Hash: SHA1

Pacho Ramos wrote:
> El lun, 02-03-2009 a las 13:01 -0800, Zac Medico escribió:
>> || ( ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) x11-libs/qt:4 )
>> It's a variation of bug 161953 [1]. For this particular variation,
>> at the moment I don't think there's a good way to distinguish that
>> the choice on the left is the better choice.
>>From my point of view, I think that portage should do something like
> calculating how much a dep is already in the system, for example, in
> this case, I have 50% of ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 )
> already installed on my system while 0% of x11-libs/qt:4. Then,
> ( x11-libs/qt-gui:4 x11-libs/qt-webkit:4 ) would be a better option
> because, hopefully, a user that has already installed a portion of this
> dep, will prefer to maintain it installed
> But, this is only theoretical as I am not a programmer and I don't know
> if this could be implemented

You're right. It's easy to says it in words but if you tried to
actually implementing you'd find that the PROPERTIES=virtual concept
simplifies the problem a lot and makes it possible to optimally
solve some cases of bug 141118 that couldn't otherwise be solved
optimally without the information that PROPERTIES=virtual provides.

What we're talking about is a cost calculation and in order for the
cost calculation to be as accurate as possible, we need to know
which ebuilds have zero-cost to install (the virtual ones do not
install anything directly so they are considered to have zero-cost
in themselves). If you consider all ebuilds to have equal cost then
your calculation won't be as accurate as it could be. Knowing which
ebuilds are virtual gives a hint to the resolver that it should
perform a "lookahead" in the cost calculation.

We could implement a similar lookahead mechanism for non-virtual
ebuilds, but it's more useful for the virtual ones. Backtracking
(which isn't implemented yet but is planned for bug 1343) would also
be useful for implementing additional cost optimizations (like the
one for bug 260225).
- --
Version: GnuPG v2.0.10 (GNU/Linux)


Thread Tools

All times are GMT. The time now is 09:19 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org