Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
unexpected results with emerge flags
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
jmckay123456789
n00b
n00b


Joined: 16 Aug 2003
Posts: 46

PostPosted: Sun Oct 12, 2003 10:01 pm    Post subject: unexpected results with emerge flags Reply with quote

I have read the portage guide and the emerge man page. However, using some flags with emerge give some unexpected results. It is easiest to see what I'm talking about with examples.

Code:
emerge -p world     

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

Calculating world dependencies ...done!
[ebuild  N    ] media-libs/libquicktime-0.9.2_pre1 
[ebuild     U ] media-video/transcode-0.6.10 [0.6.6]

OK, so I guess that transcode is the only package in my world file that needs to be updated, and I think libquicktime is a direct dependency. So far, so good.

But if I try:
Code:
sagan staging # emerge -up world   

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

Calculating world dependencies ...done!
[ebuild  N    ] media-video/nvidia-kernel-1.0.4496-r3 
[ebuild     U ] media-video/nvidia-glx-1.0.4496 [1.0.4363]
[ebuild     U ] dev-lang/nasm-0.98.38 [0.98.36]
[ebuild     U ] media-libs/libsdl-1.2.6-r1 [1.2.5-r2]
[ebuild     U ] media-video/ffmpeg-0.4.7_pre20030624 [0.4.6-r1]
[ebuild  N    ] media-libs/libquicktime-0.9.2_pre1 
[ebuild     U ] media-video/transcode-0.6.10 [0.6.6]

Hmm. Now that is strange. I don't want to upgrade my nvidia stuff for reasons I won't get into here so I specifically pinned the version number of nvidia kernal and nvidia-glx in my world file by doing:
Code:

=media-video/nvidia-kernel-1.0.4363-r3
=media-video/nvidia-glx-1.0.4363

Now I thought that "pinning" the version with an "=" sign in this way is supposed to force portage to only consider the version I specify. So when I do "emerge -up world" I would expect it to update everything to the lastest version except those packages that I have pinned. But portage is trying to update it anyway! Well, after a little reading of the portage user guide looking for a work-around I see that the correct way to update a package is "emerge -u packagename". So I tried this:
Code:
sagan staging # emerge -up transcode

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

Calculating dependencies ...done!
[ebuild  N    ] media-video/nvidia-kernel-1.0.4496-r3 
[ebuild     U ] media-video/nvidia-glx-1.0.4496 [1.0.4363]
[ebuild     U ] dev-lang/nasm-0.98.38 [0.98.36]
[ebuild     U ] media-libs/libsdl-1.2.6-r1 [1.2.5-r2]
[ebuild     U ] media-video/ffmpeg-0.4.7_pre20030624 [0.4.6-r1]
[ebuild  N    ] media-libs/libquicktime-0.9.2_pre1 
[ebuild     U ] media-video/transcode-0.6.10 [0.6.6]


Which is frustrating, because I'm pretty sure that the nvidia stuff is not a dependency of the transcode package. So how do I really "pin" a package so that I don't upgrade packages I don't want to upgrade, but I do upgrade everything else?

thanks,
Cedar
Back to top
View user's profile Send private message
meowsqueak
Veteran
Veteran


Joined: 26 Aug 2003
Posts: 1549
Location: New Zealand

PostPosted: Sun Oct 12, 2003 10:50 pm    Post subject: Reply with quote

This sort of thing always makes me shudder and recall that ominous line in 'man emerge':

Quote:
Note that --update does not have full functionality yet.


I have nightmares about what that actually means...
Back to top
View user's profile Send private message
aethyr
Veteran
Veteran


Joined: 06 Apr 2003
Posts: 1085
Location: NYC

PostPosted: Sun Oct 12, 2003 11:53 pm    Post subject: Reply with quote

Looks like it might be broken?

https://bugs.gentoo.org/show_bug.cgi?id=9847

Anyways, you don't have to use `emerge -u package` to update your packages. I frequently just `emerge package`. If you pass the -u flag, it updates any dependant packages that have newer versions available. If you don't pass the -u flag, it only upgrades those packages if they specifically require a version number higher than what you have.

So if you use `emerge -u package` you might see it installing an -r6 version of a package when you already have the -r5 version installed.
Back to top
View user's profile Send private message
jmckay123456789
n00b
n00b


Joined: 16 Aug 2003
Posts: 46

PostPosted: Mon Oct 13, 2003 1:11 am    Post subject: Reply with quote

Yeah, "emerge packagname" works in that situation, but part of the attraction of gentoo for me is the "emerge -u world" and everything is nice and up to date. I don't want to have to emerge packages one at a time to keep my world up to date. Anyway, hopefully some cool developer is on the job.

Here is a question though. If "emerge -u world" updates a package and all of its dependencies, what is the distinction between that and "emerge -D world" and "emerge -uD world"? In my case "emerge -up world" wants to update 2 packages, "emerge -pD world" wants to emerge 3 packages and "emerge -upD world" wants to emerge about 20 packages. My question is, if "-u" is supposed to consider updating dependencies, what does "-uD" consider? Dependencies of dependencies? In that case, why does "-D" only yield one extra package to update?


thanks,
Cedar
Back to top
View user's profile Send private message
meowsqueak
Veteran
Veteran


Joined: 26 Aug 2003
Posts: 1549
Location: New Zealand

PostPosted: Mon Oct 13, 2003 1:19 am    Post subject: Reply with quote

emerge -u only updates the first level of dependencies - anything below that is not upgraded. Therefore it's possible you could break something I guess.

emerge -Du will upgrade all dependencies (-D is the same as --deep).
Back to top
View user's profile Send private message
jmckay123456789
n00b
n00b


Joined: 16 Aug 2003
Posts: 46

PostPosted: Mon Oct 13, 2003 1:43 am    Post subject: Reply with quote

Speak of the devil! There was just a portage update, and now "emerge -up world" seems to want to do the right thing! Sweet!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum