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

Bug 158634

Summary: Incorrectly detected multiple versions within single slot
Product: Portage Development Reporter: Maurice van der Pot (RETIRED) <griffon26>
Component: Core - DependenciesAssignee: Portage team <dev-portage>
Status: RESOLVED DUPLICATE    
Severity: normal CC: jakub
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Maurice van der Pot (RETIRED) gentoo-dev 2006-12-20 04:08:41 UTC
I get the following message when doing emerge -puD world:

!!! Multiple versions within a single package slot have been
!!! pulled into the dependency graph:

('ebuild', '/', 'dev-perl/DBD-mysql-2.9007', 'merge') pulled in by
   ('ebuild', '/', 'www-apps/bugzilla-2.22.1', 'nomerge')

('ebuild', '/', 'dev-perl/DBD-mysql-3.0008', 'merge') (no parents)

As far as I can see there is no dependency on DBD-mysql > 2.9007, so I see no reason for portage to want to merge 3.0008. (I unmerged DBD-mysql temporarily, that's why it says 'merge' in both cases).

If I change the dep in bugzilla from: 
  mysql? ( >=virtual/mysql-4.0 <=dev-perl/DBD-mysql-3.0002 )
to:
  mysql? ( >=virtual/mysql-4.0 ~dev-perl/DBD-mysql-2.9007 )

then the output changes to:

('ebuild', '/', 'dev-perl/DBD-mysql-2.9007', 'merge') pulled in by
   ('ebuild', '/', 'www-apps/bugzilla-2.22.1', 'nomerge')

('ebuild', '/', 'dev-perl/DBD-mysql-3.0008', 'merge') pulled in by
   ('ebuild', '/', 'dev-perl/Template-Toolkit-2.15-r1', 'nomerge')

but Template-Toolkit-2.15-r1 only has the following dep:
    mysql? ( dev-perl/DBD-mysql )


Before my upgrade from portage 2.1.2_rc2-r2 to 2.1.2_rc3-r6 I had been experiencing a DBD-mysql upgrade/downgrade cycle for a long time that was probably caused by the same incorrect calculation of dependencies.

emerge --info
Portage 2.1.2_rc3-r6 (default-linux/x86/2006.1/server, gcc-4.1.1, glibc-2.5-r0, 2.6.17.6 i686)
=================================================================
System uname: 2.6.17.6 i686 Pentium III (Coppermine)
Gentoo Base System version 1.12.6
Last Sync: Wed, 20 Dec 2006 01:50:01 +0000
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.4 [disabled]
dev-java/java-config: 1.3.7, 2.0.30
dev-lang/python:     2.4.4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r6
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.14
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=pentium3 -O2 -pipe -g"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=pentium3 -O2 -pipe -g"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks fixpackages metadata-transfer nostrip parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="http://ftp.gentoo.skynet.be/pub/gentoo/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://mirrors.sec.informatik.tu-darmstadt.de/gentoo http://ftp.easynet.nl/mirror/gentoo/"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage_overlay"
SYNC="rsync://rsync.nl.gentoo.org/gentoo-portage"
USE="X Xaw3d alsa apache2 avi bitmap-fonts bonobo bzip2 cdr cli cracklib crypt cscope ctype curl dba dedicated dga dlloader dri dvd elibc_glibc encode ethereal fastcgi fbcon ffmpeg fortran gd gdbm ggi gif gpm gstreamer gtk gtk2 iconv imap imlib input_devices_keyboard isdnlog javascript jpeg kernel_linux lcms libwww mad maildir mailwrapper mbox memlimit mikmod mime mmx mozilla mp3 mpeg mpi mysql mythtv nas ncurses nocd nptl nptlonly oggvorbis pam pcre pdf pdflib perl plotutils png pnp pop pppd python qt quicktime readline reflection samba sasl sdl session slang snmp soap spell spl sse ssl svga tcltk tcpd tidy tiff truetype truetype-fonts type1-fonts udev unicode usb userland_GNU userlocales vhosts video_cards_vesa wmf wxwindows x86 xml xml2 xorg xosd xsl xv zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2006-12-20 04:21:47 UTC
More fun; just changed PDEPEND to RDEPEND in mysql.eclass and I get this now:

# USE=mysql emerge -pv bugzilla

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

Calculating dependencies /
!!! Multiple versions within a single package slot have been 
!!! pulled into the dependency graph:

('ebuild', '/', 'dev-perl/DBD-mysql-2.9007', 'merge') pulled in by
   ('ebuild', '/', 'www-apps/bugzilla-2.22.1', 'merge')

('ebuild', '/', 'dev-perl/DBD-mysql-3.0008', 'merge') pulled in by
   ('ebuild', '/', 'dev-db/mysql-5.0.30', 'merge')
   ('ebuild', '/', 'dev-perl/Template-Toolkit-2.15-r1', 'merge')
Comment 2 Zac Medico gentoo-dev 2006-12-20 08:48:25 UTC
Please attach emerge --debug output for the command that results in the error message.  This type of problem can be triggered by one package having more specific atoms than another.  Usually you can mask an unwanted version to avoid this problem (the usual workaround for bug 1343).
Comment 3 Zac Medico gentoo-dev 2006-12-20 08:59:15 UTC
I'm able to trigger the problem here.  Since bugzilla depends on <=dev-perl/DBD-mysql-3.0002, you need to mask the higher versions of dev-perl/DBD-mysql within the same slot in order to prevent bug 1343 from being triggered.  This is nothing new, it's just that portage is able to detect the problem in advance now.
Comment 4 Maurice van der Pot (RETIRED) gentoo-dev 2006-12-23 02:14:34 UTC

*** This bug has been marked as a duplicate of 1343 ***