Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 41431 - Ebuilds in multiple PORTDIR_OVERLAYs are ignored
Summary: Ebuilds in multiple PORTDIR_OVERLAYs are ignored
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-02-12 16:24 UTC by Ed Catmur
Modified: 2005-02-28 05:55 UTC (History)
1 user (show)

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


Attachments
In innermost loop replace `mycp' with `ocp' (portage-2.0.50-multiple-overlays-portage.py.patch,537 bytes, patch)
2004-02-12 16:33 UTC, Ed Catmur
Details | Diff
Alternative patch: use `[self.root]+self.overlays' to fold portage-tree and overlay cases together (portage-2.0.50-multiple-overlays-cleanup-portage.py.patch,2.30 KB, patch)
2004-02-12 16:44 UTC, Ed Catmur
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ed Catmur 2004-02-12 16:24:18 UTC
Symptoms:

emerge: there are no masked or unmasked ebuilds to satisfy ">=x11-libs/gtk+-2.3".
 
!!! Problem with ebuild x11-themes/metacity-themes-1.0
!!! Possibly a DEPEND/*DEPEND problem.
 
!!! Depgraph creation failed.

Context: emerge -Du world with 
PORTDIR_OVERLAY="/srv/gentoo/overlays/capella.catmur.co.uk/ /srv/gentoo/overlays/cvs.breakmygentoo.net/gnome-current/ " 
AND WITH ebuilds of same package but different versions in both.
	e.g. I have x11-libs/gtk+-2.2.4-r1 in capella.catmur.co.uk and this
	prevents Portage seeing x11-libs/gtk+-2.3.2-rl in cvs.breakmygentoo.net

Cause:
>>> /usr/lib/portage.pym 
@@ 4652 portdbapi.cp_list(self,mycp,use_cache=1):
		for oroot in self.overlays:
			for x in listdir(oroot+"/"+mycp,EmptyOnError=1,ignorecvs=1):
				if x[-7:]==".ebuild":
					mycp=mysplit[0]+"/"+x[:-7]
					if not mycp in returnme:
						returnme.append(mycp)

the assignment to mycp is invalid as it needs to be used for the next overlay
under consideration.
Fix is obvious; patch is on its way.
Comment 1 Ed Catmur 2004-02-12 16:33:11 UTC
Created attachment 25507 [details, diff]
In innermost loop replace `mycp' with `ocp'

Here goes.

Incidentally, would it be possible to have read-only access to the Portage cvs 

tree? Things would be easier if I could do a cvs diff rather than having to
copy
files to `foo.orig' or diffing against an `ebuild foo unpack'. OTOH if you
don't 
want randoms like me eating your bandwidth that's OK too ;)
Comment 2 Ed Catmur 2004-02-12 16:44:25 UTC
Created attachment 25508 [details, diff]
Alternative patch: use `[self.root]+self.overlays'  to fold portage-tree and overlay cases together

Code cleanup in cpv_exists, cp_all, p_list, cp_list
e.g.
	def p_list(self,mycp):
		returnme=[]
		ignorecvs=0
		for root in [self.root]+self.overlays:
			for x in
listdir(root+"/"+mycp,EmptyOnError=1,ignorecvs=ignorecvs):
				if x[-7:]==".ebuild":
					mye=x[:-7]
					if not mye in returnme:
						returnme.append(mye)
			ignorecvs=1
		return returnme

I think this is cleaner, anyway :)
Comment 3 Brian Harring (RETIRED) gentoo-dev 2005-02-27 23:57:06 UTC
This should work fine... I run with overlays w/ similar cp's and differing versions, and have for quite some time...
Comment 4 Ed Catmur 2005-02-28 05:55:55 UTC
Yeah, it was fixed on the tree back in March of last year:

http://www.gentoo.org/cgi-bin/viewcvs.cgi/portage/pym/portage.py?root=gentoo-src#rev1.401

Sorry for not closing this bug myself.