Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 13632

Summary: "emerge --update --deep world" keeps wanting to upgrade and then downgrade packages
Product: Portage Development Reporter: Douglas Pollock <douglas.pollock>
Component: UnclassifiedAssignee: Portage team <dev-portage>
Status: RESOLVED DUPLICATE    
Severity: major CC: A-Mann, andre.hinrichs, avuton, belgix_oz, betelgeuse, christoph.gysin, dertobi123, douglas.pollock, ecd, g1gsw, gentoo-bugs, gentoo-bugs, gentoo-bugs, gentoobugs, greg_g, grossk, henrik, iyosifov, jbc28, jnagyjr, lafou, mholzer, netbox253, phoenixreads, radek, reg, rl, sascha-gentoo-bugzilla, squee, tyler, zeroth
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 33440    
Bug Blocks:    
Attachments: World File for the Affected System
Make Configuration
output of emerge --info of the Evandro system

Description Douglas Pollock 2003-01-10 06:31:44 UTC
Sorry if this is a duplicate, but I wasn't able to find a match.

The problem is that "emerge --update --deep world" changes its mind about which
package version should be used.  For example, right now it reports (where
"sbin/emerge.sh" is a script that remounts the "/usr" partition writable, runs
the emerge request, and then remounts "/usr" read-only):

dragon root # sbin/emerge.sh -pu --deep world
Making the portage tree writable....
Executing your emerge request (ten arguments, low priority)....

These are the packages that I would merge, in order:

Calculating world dependencies ...done!
[ebuild    U ] app-admin/gentoolkit-0.1.17-r9 [0.1.17-r8]
[ebuild    U ] app-cdr/cdrtools-2.0 [1.11.33-r0]
[ebuild    UD] media-libs/xine-lib-0.9.13-r2 [1_beta2-r0]

Locking down the portage tree again....
dragon root # 


Now, the last time I ran update, I had cdrtools-2.0-r0 and xine-lib-1_beta2-r0
installed.  Strangely enough, it wanted to run the inverse update (i.e.,
downgrade to cdrtools-1.11.33-r0 and upgrade (!) to xine-lib-0.9.13-r2).  There
appears to be a loop.

I'll attach my world file.


P.S.  Perhaps unrelated, but my gimp recently crashed and could not be reopened
after an update (it was open during the update).  Destroying the user
preferences and remerging gimp did not fix.  It required destroying the user
preferences and "emerge -e gimp".
Comment 1 Douglas Pollock 2003-01-10 06:33:14 UTC
Created attachment 7161 [details]
World File for the Affected System
Comment 2 Douglas Pollock 2003-01-21 07:47:54 UTC
Created attachment 7504 [details]
Make Configuration
Comment 3 Douglas Pollock 2003-02-11 16:49:37 UTC
I don't know whether you've changed anything in portage or not, but I've stopped 
seeing this behaviour. 
Comment 4 becker.steffen 2003-02-21 06:00:47 UTC
Hi, 
same problem here for a few days: 
 
root@frodo:/root> emerge -up --deep world 
 
These are the packages that I would merge, in order: 
 
Calculating world dependencies ...done! 
[ebuild    UD] media-video/avifile-0.7.15.20020816-r1 [0.7.32.20030219] 
 
After doing a emerge -u --deep world and compiling/merging of 
media-video/avifile-0.7.15.20020816-r1: 
 
root@frodo:/root> emerge -up --deep world 
 
These are the packages that I would merge, in order: 
 
Calculating world dependencies ...done! 
[ebuild    U ] media-video/avifile-0.7.32.20030219 [0.7.15.20020816-r1] 
 
So, it's caught in a loop. Can I supply any additional data/information. World file, 
Cache-files, etc?? 
Comment 5 Martin Holzer (RETIRED) gentoo-dev 2003-03-02 06:32:03 UTC
avifile causes from transcode

DEPEND="	avi? ( <=media-video/avifile-0.7.22
		>=media-video/avifile-0.7.4 )"

Comment 6 Douglas Pollock 2003-03-19 13:15:45 UTC
What version of xine-lib is supposed to exist?  It wants to UD my xine-lib again.  
Am I supposed to have 0.9.13 or the 1.0_beta?  It is a horrible waste of my CPU 
time to keep switching back and forth. 
Comment 7 Martin Holzer (RETIRED) gentoo-dev 2003-07-09 13:34:17 UTC
*** Bug 24134 has been marked as a duplicate of this bug. ***
Comment 8 Martin Holzer (RETIRED) gentoo-dev 2003-07-09 15:05:11 UTC
*** Bug 24205 has been marked as a duplicate of this bug. ***
Comment 9 Squee 2003-07-09 17:07:39 UTC
Same problem (was one of the duplicate reports of this bug) and here's some output for avifile problems I'm getting:

# qpkg -q avifile

media-video/avifile-0.7.32.20030219 *
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1
media-video/avifile-0.7.15.20020816-r1
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1
media-video/avifile-0.7.32.20030219
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1
media-video/avifile-0.7.34.20030319
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1
media-video/avifile-0.7.37.20030522
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1
media-video/avifile-0.7.37.20030522-r1
DEPENDED ON BY:
        media-video/drip-0.8.2_pre1

From the ebuild file:
RDEPEND="gnome-base/gnome-libs
        <media-video/avifile-0.7.22
        >=media-video/avifile-0.7.4.20020426-r2

Drip is the only thing I have that depends on avifile.  This means it really shouldn't be upgrading/downgrading packages like that...right?

Oh, and libmpeg2 has a problem as well for me, drip depends on it. From drip ebuild:
RDEPEND=
...
=media-libs/libmpeg2-0.2.1*

# qpkg -q libmpeg2
media-libs/libmpeg2-0.3.1 *
DEPENDED ON BY:
        media-libs/gst-plugins-0.6.1
        media-video/drip-0.8.2_pre1
media-libs/libmpeg2-0.2.1
DEPENDED ON BY:
        media-libs/gst-plugins-0.6.1
        media-video/drip-0.8.2_pre1
media-libs/libmpeg2-0.3.1
DEPENDED ON BY:
        media-libs/gst-plugins-0.6.1
        media-video/drip-0.8.2_pre1
media-libs/libmpeg2-0.3.2_pre20030625
DEPENDED ON BY:
        media-libs/gst-plugins-0.6.1
        media-video/drip-0.8.2_pre1

gst-plgugins ebuild:
RDEPEND=
...
        mpeg? ( =media-libs/libmpeg2-0.3.1* )


The = in both drip and gst-plugins causes the problem there.  Anyway, I could just remove drip, but I'd rather not...
Comment 10 Martin Holzer (RETIRED) gentoo-dev 2003-07-15 01:57:26 UTC
*** Bug 24505 has been marked as a duplicate of this bug. ***
Comment 11 Martin Holzer (RETIRED) gentoo-dev 2003-07-15 04:33:09 UTC
*** Bug 24515 has been marked as a duplicate of this bug. ***
Comment 12 Markus Luisser 2003-07-15 09:40:32 UTC
i have the same problem with vim-core - forum thread is here: http://forums.gentoo.org/viewtopic.php?p=414084

<workaround>
i found that CTRL-C during the countdown for the unmerge step is a dirty workaround for the problem. when both versions are emerged it works as it should. perhaps this also works with injecting (didnt test though)...
</workaround>
Comment 13 Charles Phoenix 2003-08-11 19:40:47 UTC
see #16240, netbpm upgrades, downgrades, upgrades, etc.

after entering emerge -upD world

emerge wants to upgrade netbpm and then downgrade netpbm. Info with #16240

I don't have transcode installed

portage version: 2.0.48-r7
Comment 14 Doc Funfrock 2003-10-06 11:29:47 UTC
I have the same behaviour with KDE!
Comment 15 Tobias Scherbaum (RETIRED) gentoo-dev 2003-10-06 13:03:45 UTC
It might be an workaround to "--inject" the old version which portage wants
to downgrade.
Comment 16 David Bergstein 2003-11-09 06:43:36 UTC
I'm seeing the same behavior, portage wants to downgrade a package (qt-3.2.2-r1)
that is marked as stable (x86):

emerge -uUpvD world

These are the packages that I would merge, in order:

Calculating world dependencies ...done!
[ebuild     UD] x11-libs/qt-3.1.2-r4 [3.2.2-r1] +cups -nas -postgres +opengl
-mysql -odbc +gif -debug
Comment 17 Andre Hinrichs 2004-06-10 03:12:39 UTC
I now have this behavior with libgcrypt.
'emerge -Dup world' upgrades libgcrypt to version 1.1.94 but dependencies of
several packages (opencdk and newpg) say it must stay on version 1.1.12 which is
perfectly ok since 1.1.94 breaks everything causing several packages to fail
compiling. So next time running 'emerge -Dup world' he downgrades again to version
1.1.12. This is an infinitive loop...
I did some investigation of the ebuilds and found that none of the installed
packages requires a newer version than 1.1.12. So why does emerge want to
upgrade? Since the ebuilds and their dependencies seem to be correct I assume
it is a bug in the portage tools.
Comment 18 Brian Harring (RETIRED) gentoo-dev 2004-06-18 11:46:51 UTC
Andre, I'd be curious if you have libgcrypt in your world file...
Comment 19 Andre Hinrichs 2004-06-20 07:40:47 UTC
Of course, it's not in my world file.
The dependency loop is caused by the newpg package.
But after all I think portage tools should take care of this and throw an
dependency error, shouldn't they?

Off topic:
I've given up now and deleted newpg to get rid of this dependency loop since it
is also declared 'dead' by the GNU people. Now looking for an alternative,
since encryption in KMail is currently not working. Will try to rebuild world
now to see what happens.
Comment 20 Jason Stubbs (RETIRED) gentoo-dev 2004-10-05 03:45:47 UTC
*** Bug 66402 has been marked as a duplicate of this bug. ***
Comment 21 Jason Stubbs (RETIRED) gentoo-dev 2004-10-05 03:53:52 UTC
*** Bug 66403 has been marked as a duplicate of this bug. ***
Comment 22 Jason Stubbs (RETIRED) gentoo-dev 2004-10-25 06:44:39 UTC
*** Bug 68757 has been marked as a duplicate of this bug. ***
Comment 23 Steven Hay 2004-10-27 19:01:19 UTC
My system is doing this with gst-plugins.  I've got gnome 2.8 in ~arch installed.

-puD tries to downgrade it, -pu upgrades.

I can post whatever data you guys would find useful; let me know.
Comment 24 Jason Stubbs (RETIRED) gentoo-dev 2004-10-28 05:21:29 UTC
The root cause of the problem is known but the fix is quite complex. I highly doubt that the fix will make it into the 2.0.51 line at all. It will be in the subsequent version, however.
Comment 25 Jason Stubbs (RETIRED) gentoo-dev 2004-11-30 05:25:30 UTC
*** Bug 72568 has been marked as a duplicate of this bug. ***
Comment 26 Jason Stubbs (RETIRED) gentoo-dev 2004-11-30 05:26:16 UTC
*** Bug 57011 has been marked as a duplicate of this bug. ***
Comment 27 Jason Stubbs (RETIRED) gentoo-dev 2004-12-10 17:28:43 UTC
*** Bug 42974 has been marked as a duplicate of this bug. ***
Comment 28 Evandro Clivatti Dall'Agnol 2005-01-29 09:34:46 UTC
I'm having the same problema with xorg-x11. It keeps upgrading and downgrading between 6.7.0-r3 and 6.8.0-r4. It is in my world file. It's not fun waiting around an hour every time :) I'll to attach my --info output here too.
--------
bagual root # emerge --update --deep world --pretend

These are the packages that I would merge, in order:

Calculating world dependencies ...done!
[ebuild     UD] x11-base/xorg-x11-6.7.0-r3 [6.8.0-r4]
--------
Comment 29 Evandro Clivatti Dall'Agnol 2005-01-29 09:37:48 UTC
Created attachment 49844 [details]
output of emerge --info of the Evandro system
Comment 30 Jason Stubbs (RETIRED) gentoo-dev 2005-01-29 19:03:12 UTC
Can you give "emerge -uDtp world" output when it is wanting to *downgrade*, please?
Comment 31 Evandro Clivatti Dall'Agnol 2005-01-30 19:13:22 UTC
bagual root # emerge -uDtp world

These are the packages that I would merge, in reverse order:

Calculating world dependencies ...done!
[nomerge      ] media-video/ati-drivers-3.14.6  
[ebuild     UD]  x11-base/xorg-x11-6.7.0-r3 [6.8.0-r4]
Comment 32 Evandro Clivatti Dall'Agnol 2005-01-30 19:22:17 UTC
And after a emerge --sync:

bagual root # date
Mon Jan 31 01:20:16 BRST 2005
bagual root # emerge -uDtp world

These are the packages that I would merge, in reverse order:

Calculating world dependencies ...done!
[nomerge      ] media-plugins/xmms-xmmsmplayer-0.5  
[nomerge      ]  media-video/mplayer-1.0_pre5-r5  
[ebuild     U ]   media-libs/win32codecs-20050115 [20040916-r1] 
[nomerge      ] media-video/ati-drivers-3.14.6  
[ebuild     UD]  x11-base/xorg-x11-6.7.0-r3 [6.8.0-r4] 
[nomerge      ] x11-terms/xterm-197  
[nomerge      ]  sys-apps/utempter-0.5.5.5-r1  
[nomerge      ]   app-arch/rpm2targz-9.0-r2  
[ebuild     U ]    app-arch/cpio-2.6-r1 [2.5]
Comment 33 Jason Stubbs (RETIRED) gentoo-dev 2005-01-31 04:08:26 UTC
ati-drivers-3.14.6 requires <x11-base/xorg-x11-6.7.99. So, if you wish to use ati-drivers, you're probably best-off masking >=x11-base/xorg-x11-6.8. Once this bug is fixed, that is essentially the behavior that you will get.
Comment 34 Jason Stubbs (RETIRED) gentoo-dev 2005-03-05 08:40:07 UTC
*** Bug 84198 has been marked as a duplicate of this bug. ***
Comment 35 Nicholas Jones (RETIRED) gentoo-dev 2005-03-06 17:41:22 UTC
Packages having issues like ati-drivers should probably block the opposite direction of the requirement... so block all newer xorgs. Assuming that is
reasonable for the package.
Comment 36 Roger Luethi 2005-04-13 00:34:54 UTC
I'm seeing this effect with valgrind 2.2.0-r2 and 2.4.0 now (with package keyword ~x86).
Comment 37 Jason Stubbs (RETIRED) gentoo-dev 2005-04-14 05:20:43 UTC
Please. The cause of this bug is known. How to fix it is known. It's not a small task but is being worked on. Please don't waste time by causing more junk mail.
Comment 38 Diego Elio Pettenò (RETIRED) gentoo-dev 2005-04-25 06:48:29 UTC
*** Bug 57269 has been marked as a duplicate of this bug. ***
Comment 39 Diego Elio Pettenò (RETIRED) gentoo-dev 2005-04-28 18:04:23 UTC
*** Bug 90786 has been marked as a duplicate of this bug. ***
Comment 40 Jason Stubbs (RETIRED) gentoo-dev 2005-05-01 10:03:20 UTC
*** Bug 67677 has been marked as a duplicate of this bug. ***
Comment 41 Ivan Yosifov 2005-06-16 09:46:50 UTC
(In reply to comment #37)
> Please. The cause of this bug is known. How to fix it is known. It's not a
small task but is being worked on. Please don't waste time by causing more junk
mail.


Ok, I can understand your frustration from feeling pressured. 
I hope you can understand a users frustration from feeling ignored. 
After 3 years, can you, please, at least give a short explanation on what the
problem really is ? 
Comment 42 Jason Stubbs (RETIRED) gentoo-dev 2005-06-16 10:16:22 UTC
Portage ignores dependencies on a package if it is already installed. 
Comment 43 Ivan Yosifov 2005-06-17 12:48:56 UTC
By package you mean package-<version>, not just package name, right ?
So portage thinks that by updating foo-1.0 to foo-2.0 nothing will be broken,
since it does not actually look at what depends on foo-1.0. On the next update 
foo-1.0 is no longer installed, so portage finds out that apps depend on it and
wants to downgrade foo-2.0 to foo-1.0 .

Am I understanding it right ?
Comment 44 Petteri Räty (RETIRED) gentoo-dev 2005-08-12 05:01:44 UTC
*** Bug 102208 has been marked as a duplicate of this bug. ***
Comment 45 Petteri Räty (RETIRED) gentoo-dev 2005-08-12 05:07:30 UTC
(In reply to comment #43)
> 
> Am I understanding it right ?

At least here one upgrade/downgrade cycle was caused by having one of the deps
in the world file. Both callgrind and valgrind are in the world file so here is
what happens: It seems portage goes trough all the items one by one so when it
looks at callgrind it does not want to update valgrind because the dep is =2*,
but when it comes to valgrind it does want to update it because it does not
check for anything else. So with emerge -uD world valgrind goes up to 3.0.0 and
back again with callgrind installed. Hopefully this explained at least one
possible cause of this problem. I recommend using emerge -uDpvt in tracking the
problem you might have. 
Comment 46 Ivan Yosifov 2005-08-12 05:43:37 UTC
> I recommend using emerge -uDpvt in tracking the
> problem you might have. 

That's what I am currently doing. Hopefully, now that portage-2.1.0_alpha20050718
is in portage, this bug will be soon dead and buried.
Comment 47 Marek Kwasceki 2005-09-03 12:04:36 UTC
i have observed valgrind problem from bug 102208

and now as an addition, while doing 
 #emerge -Dupv world 
I see:

[ebuild     UD] dev-util/valgrind-2.4.1 [3.0.0] +X 
[ebuild     U ] dev-util/valgrind-3.0.1 [3.0.0] +X 

how about that?
Comment 48 Jason Stubbs (RETIRED) gentoo-dev 2005-10-07 07:26:39 UTC

*** This bug has been marked as a duplicate of 1343 ***
Comment 49 Garrett Cooper 2005-12-08 18:38:49 UTC
For the time being, if people are pointed to this bug, with the proper amount of
version masking and unmasking, one can combat this issue [somewhat]. For me it
was gtk+, and by adding the following lines, I could keep a stable version of
the gtk+1.2.x branch and also use gtk+2.8.8:

portage.mask:
>x11-libs/gtk+-2.8.8 #mask all versions higher than 2.8.8.
#...
<x11-libs/gtk+-2.8.8 #mask all versions less than 2.8.8

portage.unmask:
<x11-libs/gtk+-2.0 #unmask all versions less than 2.0

I know it's a bit barbaric and I could have accomplished the same with 2 lines,
but at least it gets rid of the annoying 2.6.10-r[blah] recompile message.

I try making a quick and dirty script for package masking/unmasking management
after my school quarter ends.
Comment 50 Zac Medico gentoo-dev 2006-08-06 02:50:45 UTC
*** Bug 142848 has been marked as a duplicate of this bug. ***
Comment 51 Nirbheek Chauhan (RETIRED) gentoo-dev 2009-07-22 06:09:59 UTC
*** Bug 278568 has been marked as a duplicate of this bug. ***