Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Portage & Programming
  • Search

How to list all unavailable packages?

Problems with emerge or ebuilds? Have a basic programming question about C, PHP, Perl, BASH or something else?
Post Reply
Advanced search
13 posts • Page 1 of 1
Author
Message
happysmash27
Apprentice
Apprentice
Posts: 220
Joined: Mon Mar 28, 2016 10:37 pm

How to list all unavailable packages?

  • Quote

Post by happysmash27 » Fri Sep 24, 2021 6:50 pm

For years, Portage has been failing to install things with convoluted error messages that must be traced down to some packages that are installed, but are no longer available, blocking any packages which depend on them for updating, which requires me to start adding packages to my list of packages to install one by one until it says it is not available.

Today, I decided to try to update all installed Python packages. This fails similarly; one by one, going through the list of packages, it will say, `emerge: there are no ebuilds to satisfy "dev-python/futures"` or something like that, and it will only list that one package, not any others, requiring me to uninstall that program, then re-run the same command to find whatever the next program is unavailable. This has made me realise, that the problem the entire time, that always stops my emerge commands from running, is that one unavailable package is blocking all the others, and that is why adding more packages to my emerge command, seems to help fix things. This results in really huge commands that are hard to deal with.

There is a super nice package set that would be perfect for this, @unavailable, but I have not found any way to actually list the packages in it. If I run emerge --pretend @unavailable, it just lists that they can not be installed, one by one!

Isn't there a more efficient way to do this? Maybe if I could get some comprehensive list of all the unavailable packages on my system, I could actually update it instead of being locked in perpetual gridlock where every single update is a labour-intensive process of isolating packages one-by-one.
Top
mike155
Advocate
Advocate
Posts: 4438
Joined: Fri Sep 17, 2010 11:33 pm
Location: Frankfurt, Germany

  • Quote

Post by mike155 » Fri Sep 24, 2021 7:34 pm

For years, Portage has been failing to install things with convoluted error messages that must be traced down to some packages that are installed, but are no longer available, blocking any packages which depend on them for updating, which requires me to start adding packages to my list of packages to install one by one until it says it is not available.
Could you give an example for an installed package that is no longer available, please?

I have used Gentoo for more than 15 years - but I've never had a package that is no longer available??? I'm afraid I don't understand what you are talking about???
Top
Josef.95
Advocate
Advocate
Posts: 4857
Joined: Mon Sep 03, 2007 9:46 am
Location: Germany

  • Quote

Post by Josef.95 » Fri Sep 24, 2021 7:39 pm

Not sure, but I think

Code: Select all

emerge -pvO @unavailable
should probably list all.
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56073
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Fri Sep 24, 2021 8:04 pm

happysmash27,

That implies that you have world file pollution. There are things there that have been removed from ::gentoo, or you have not been doing --depclean as par of your maintenance, or both.
World file pollution happens when you should use --oneshot but forget.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
happysmash27
Apprentice
Apprentice
Posts: 220
Joined: Mon Mar 28, 2016 10:37 pm

  • Quote

Post by happysmash27 » Fri Sep 24, 2021 8:53 pm

NeddySeagoon wrote:happysmash27,

That implies that you have world file pollution. There are things there that have been removed from ::gentoo, or you have not been doing --depclean as par of your maintenance, or both.
World file pollution happens when you should use --oneshot but forget.
I realised I should be using --oneshot a while ago, stopped running commands without it when I should use it, and cleaned my world file some. It is still probably polluted though due to the time I did not use it.

I did NOT realise running depclean without a specific package specified was a thing one could do, however. Thank you so much for this command!! This is extremely helpful advice.

Depclean, however, fails due to required packages that could not be resolved, and says:

Code: Select all

 * Have you forgotten to do a complete update prior to depclean? The
 * most comprehensive command for this purpose is as follows:
 *
 *   emerge --update --newuse --deep --with-bdeps=y @world
Which does complicate things, since updating @world almost always results in at least one error along the way.

But, the next time things are updated, I will definitely run that. I am guessing it could probably solve a lot of my issues.
Top
Hu
Administrator
Administrator
Posts: 24380
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Fri Sep 24, 2021 9:05 pm

You might (or might not) be able to make the world update go more smoothly if you clean up your world file first, either manually or via emerge --deselect. On the one hand, this will reduce the set of packages that Portage will try to update for your next @world, which may let it ignore packages that you don't need and that will trouble you. On the other hand, it will reduce the set of packages that Portage will try to update, which may cause a conflict because Portage tries to avoid upgrading this "unnecessary" package, and can only solve the dependency graph if the upgrade is performed.

You could use emerge --unmerge to remove specific named packages. However, this has minimal sanity checking, and you can carelessly remove a critical package, making the system much harder to use. The forum has plenty of threads from people who used emerge --unmerge to remove something that was vital to the toolchain, leaving the system unable to rebuild itself.
Top
cboldt
Veteran
Veteran
User avatar
Posts: 1046
Joined: Wed Aug 24, 2005 2:54 pm

  • Quote

Post by cboldt » Fri Sep 24, 2021 10:04 pm

What is a good way to figure out what packages are listed in "world" that don't need to be listed in "world"?

Not neat, and slow, and has some quirks, I used this to find packages that WOULD be removed, which suggests that they need to be in the "world" file, unless I choose to give up the functions that package provides.

Code: Select all

for i in `cat /var/lib/portage/world`;do emerge --depclean -p $i;done
Top
mike155
Advocate
Advocate
Posts: 4438
Joined: Fri Sep 17, 2010 11:33 pm
Location: Frankfurt, Germany

  • Quote

Post by mike155 » Fri Sep 24, 2021 10:35 pm

There are some more scripts in this thread: https://forums.gentoo.org/viewtopic-t-1075276.html and on this page: https://wiki.gentoo.org/wiki/User:Vaukai/checkworldfile

I agree with Jaglovers post: https://forums.gentoo.org/viewtopic-p-8 ... ml#8169114, but the scripts may help for an initial cleanup.
Top
cboldt
Veteran
Veteran
User avatar
Posts: 1046
Joined: Wed Aug 24, 2005 2:54 pm

  • Quote

Post by cboldt » Fri Sep 24, 2021 11:19 pm

Yeah - Those scripts uses emerge--depclean -p (and results do have some quirks, for example putting a specific gentoo-sources::version in world), and I see use of qdepends in there too.

Agree with you and w/jaglover. The results are a guide, use care, etc. I use lynx all the time, every day browser. By instinct thought it should be in world, but turns out it is a dependency of other programs that are on my systems. No harm if it's kept in world (I want to keep it no matter what), but it need not be there, and I get a (small) kick out of having the fewest number of entries in world.

Edit to add - this is way quicker, but takes a bit of work to interpret results:

Code: Select all

for i in `cat /var/lib/portage/world`;do printf "$i:\n";qdepends -Q -q $i;done
Rather than edit world by hand (not that I mind doing that), the emerge commands can remove and add, in between tests of emerge --depclean.

emerge --deselect <pacgkagename> to remove
emerge --select -n <packagename> to add. The "-n" skips recompile, assuming you haven't removed the package from the system.
Top
Tony0945
Watchman
Watchman
Posts: 5127
Joined: Tue Jul 25, 2006 12:19 am
Location: Illinois, USA

  • Quote

Post by Tony0945 » Sat Sep 25, 2021 1:29 am

Code: Select all

~ $ emerge -pvO @unavailable

These are the packages that would be merged, in order:


emerge: there are no ebuilds to satisfy "app-emulation/wine-mono:4.9.4".
(dependency required by "@unavailable" [argument])
Never heard of that target before!
Top
figueroa
Advocate
Advocate
User avatar
Posts: 3032
Joined: Sun Aug 14, 2005 8:15 pm
Location: Edge of marsh USA
Contact:
Contact figueroa
Website

  • Quote

Post by figueroa » Sat Sep 25, 2021 2:37 am

The pretend output of eclean will show you installed but unavailable packages.

Code: Select all

eclean-dist -p -d
...
 [   11.4 G ] Total space from 1023 files would be freed in the distfiles directory

   The following unavailable installed packages were found
             games-action/dungeon-3.2.3
             sys-kernel/gentoo-sources-4.9.276
Andy Figueroa
hp pavilion hpe h8-1260t/2AB5; spinning rust x3
i7-2600 @ 3.40GHz; 16 gb; Radeon HD 7570
amd64/23.0/split-usr/desktop (stable), OpenRC, -systemd -pulseaudio -uefi -wayland
Top
cboldt
Veteran
Veteran
User avatar
Posts: 1046
Joined: Wed Aug 24, 2005 2:54 pm

  • Quote

Post by cboldt » Sat Sep 25, 2021 9:40 am

eix-test-obsolete is another tool that shows (among many other things) installed but unavailable packages.
Top
Irre
Guru
Guru
Posts: 434
Joined: Sat Nov 09, 2013 10:03 am
Location: Stockholm

  • Quote

Post by Irre » Sun Sep 26, 2021 6:34 am

emaint world :)
Top
Post Reply

13 posts • Page 1 of 1

Return to “Portage & Programming”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy