Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 248026 - sys-apps/portage-2.1.4.5: emerge --depclean fails with Dependencies could not be completely resolved
Summary: sys-apps/portage-2.1.4.5: emerge --depclean fails with Dependencies could not...
Status: IN_PROGRESS
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
: 266647 (view as bug list)
Depends on:
Blocks: 144480 155723
  Show dependency tree
 
Reported: 2008-11-21 18:06 UTC by Pacho Ramos
Modified: 2021-06-19 18:29 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pacho Ramos gentoo-dev 2008-11-21 18:06:20 UTC
Just after running succesfully "emerge -avuDN world", emerge -a --depclean fails with the following error:
Calculating dependencies... done!

Dependencies could not be completely resolved due to
the following required packages not being installed:

virtual/perl-ExtUtils-CBuilder required by perl-core/File-Spec-3.25

Have you forgotten to run `emerge --update --newuse --deep world` prior to
depclean?  It may be necessary to manually uninstall packages that no longer
exist in the portage tree since it may not be possible to satisfy their
dependencies.  Also, be aware of the --with-bdeps option that is documented
in `man emerge`.

 * GNU info directory index is up-to-date.

I have re-run emerge -avuDN world and I get the same, then, I have run:
# emerge -C File-Spec

Then, I get the following:
Calculating dependencies... done!

Dependencies could not be completely resolved due to
the following required packages not being installed:

~perl-core/File-Spec-3.25 required by virtual/perl-File-Spec-3.25 dev-perl/Archive-Zip-1.20

And I run again:
# emerge -C virtual/perl-File-Spec-3.25 dev-perl/Archive-Zip-1.20

And, finally, I can run emerge --depclean properly :-)

I am not sure if this is a real bug or I am doing something wrong, but I have finally reported it because I have find this problem in all gentoo systems I have updated recently

Thanks

Portage 2.1.4.5 (default/linux/amd64/2008.0/desktop, gcc-4.1.2, glibc-2.6.1-r0, 2.6.26-tuxonice x86_64)
=================================================================
System uname: 2.6.26-tuxonice x86_64 Intel(R) Core(TM)2 Duo CPU T9300 @ 2.50GHz
Timestamp of tree: Fri, 21 Nov 2008 17:08:02 +0000
ccache version 2.4 [enabled]
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.5.2-r7
dev-util/ccache:     2.4-r7
dev-util/cmake:      2.4.8
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r2
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1-r1
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.23-r3
ACCEPT_KEYWORDS="amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=nocona -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O2 -pipe -march=nocona -fomit-frame-pointer"
DISTDIR="/usr/distfiles"
FEATURES="autoaddcvs ccache collision-protect cvs distlocks metadata-transfer multilib-strict parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="ftp://ftp.free.fr/mirrors/ftp.gentoo.org"
LANG="es_ES.UTF-8"
LC_ALL="es_ES.UTF-8"
LDFLAGS="-Wl,-O1"
LINGUAS="es es_ES en_US"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage/layman/sunrise /usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 avahi bash-completion berkdb bluetooth branding bzip2 cairo cdda cddb cdparanoia cdr cli consolekit cracklib crypt css cups daap dbus dell divx djvu dts dvd dvdr dvdread dvi eds emboss emovix encode epiphany evo exif fam fbcondecor fbsplash ffmpeg flac fortran fuse galago gdbm gif glitz gmedia gnome gnome-keyring gpm gstreamer gtk hal iconv ieee1394 ipv6 isdnlog java java6 jpeg kdeenablefinal kdehiddenvisibility kpathsea ladspa laptop latex lcms ldap libnotify lirc lzma mad midi mikmod mjpeg mmx mono moonlight mp3 mpeg mudflap multilib musepack musicbrainz nautilus ncurses network network-cron nls nptl nptlonly ogg opengl openmp pam pch pcre pdf perl png ppds pppd python qt3 qt3support qt4 quicktime readline realmedia reflection scanner sdl session smp speex spell spl sse sse2 ssl ssse3 startup-notification svg sysfs t1lib tcpd theora threads tiff totem truetype unicode usb vcd vorbis wmf wmp xattr xcb xft xinetd xml xorg xulrunner xv xvid zeroconf zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="es es_ES en_US" USERLAND="GNU" VIDEO_CARDS="nvidia nv"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS


Reproducible: Always
Comment 1 Zac Medico gentoo-dev 2008-11-25 07:45:09 UTC
I(In reply to comment #0)
> Just after running succesfully "emerge -avuDN world", emerge -a --depclean
> fails with the following error:
> Calculating dependencies... done!
> 
> Dependencies could not be completely resolved due to
> the following required packages not being installed:
> 
> virtual/perl-ExtUtils-CBuilder required by perl-core/File-Spec-3.25
> 
> Have you forgotten to run `emerge --update --newuse --deep world` prior to
> depclean?  It may be necessary to manually uninstall packages that no longer
> exist in the portage tree since it may not be possible to satisfy their
> dependencies.  Also, be aware of the --with-bdeps option that is documented
> in `man emerge`.

A likely explanation is that the perl-core/File-Spec-3.25 dependencies were changed sometime after you had installed it, and the update command that you used didn't pull in the new dependencies they were build-time only and you hadn't specified --with-bdeps=y.

In case you're wondering, the reason that dependencies can change after install is that the live ebuild dependencies are used as a workaround for problematic dependencies such as those generated qt3.eclass and it's QT3VERSIONS variable (see bug #239006, comment #4 for more details).

Anyway, I intend to solve poor depclean behavior that you've reported by using ebuilds to complete the dependency graph when possible, which should make it safer for --depclean to tolerate missing dependencies.
Comment 2 Pacho Ramos gentoo-dev 2008-11-25 18:33:34 UTC
OK, thanks a lot for the explanation :-)
Comment 3 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2009-04-18 20:12:47 UTC
*** Bug 266647 has been marked as a duplicate of this bug. ***
Comment 4 Zac Medico gentoo-dev 2009-04-20 18:32:14 UTC
*** Bug 266861 has been marked as a duplicate of this bug. ***
Comment 5 Ben Kohler gentoo-dev 2014-08-01 19:51:22 UTC
Is this still a problem? Depclean now suggests an emerge command with --with-bdeps=y in it
Comment 6 Zac Medico gentoo-dev 2021-06-18 20:16:13 UTC
What we really need as an emerge command that will attempt to perform the minimal changes necessary to correct the identified problems. In its simplest form, it would essentially take the unresolved dependencies and essentially feed those as arguments to emerge --oneshot (and as usual the user can add --usepkg if they'd like to use binary packages for this).
Comment 7 Zac Medico gentoo-dev 2021-06-18 20:18:46 UTC
(In reply to Zac Medico from comment #6)
> What we really need as an emerge command that will attempt to perform the
> minimal changes necessary to correct the identified problems. In its
> simplest form, it would essentially take the unresolved dependencies and
> essentially feed those as arguments to emerge --oneshot (and as usual the
> user can add --usepkg if they'd like to use binary packages for this).

For broken built slot operator deps, we'd want it to omit the built slot/subslot component in the emerge argument, so that it can rebuild against a new slot/subslot if needed.
Comment 8 Zac Medico gentoo-dev 2021-06-18 20:54:58 UTC
Planning an @unsatisfied-deps package set for this.
Comment 10 Zac Medico gentoo-dev 2021-06-19 03:17:49 UTC
(In reply to Zac Medico from comment #8)
> Planning an @unsatisfied-deps package set for this.

It turns out that @unsatisfied-deps is not really the solution to this bug, because it is often unsuitable in the sense that it pulls in a bunch of @installed packages (@preserved-rebuild has a similar caveat), when you really want to use @world as the source of truth.
Comment 11 Zac Medico gentoo-dev 2021-06-19 18:29:31 UTC
(In reply to Zac Medico from comment #10)
> (In reply to Zac Medico from comment #8)
> > Planning an @unsatisfied-deps package set for this.
> 
> It turns out that @unsatisfied-deps is not really the solution to this bug,
> because it is often unsuitable in the sense that it pulls in a bunch of
> @installed packages (@preserved-rebuild has a similar caveat), when you
> really want to use @world as the source of truth.

My plan is it introduce an @unsatisfied-world set which is equivalent to @unsatisfied-deps but filters out any non @world packages.