From 0d228ecba942810e6ad13c70e9e9f9eaf578db6c Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Wed, 20 Jun 2007 05:08:10 +0000 Subject: If a package is in the world set but it's not installed, go ahead and install it if it's available (instead of telling the user to run emaint). svn path=/main/trunk/; revision=6883 --- pym/emerge/__init__.py | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/pym/emerge/__init__.py b/pym/emerge/__init__.py index 5d7c69615..bf6dd5a36 100644 --- a/pym/emerge/__init__.py +++ b/pym/emerge/__init__.py @@ -2217,10 +2217,22 @@ class depgraph: for x in worlddict.keys(): if not portage.isvalidatom(x): world_problems = True - elif not self.trees[self.target_root]["vartree"].dbapi.match(x): - world_problems = True - else: - mylist.append(x) + continue + elif not vardb.match(x): + available = False + if "--usepkgonly" not in self.myopts and \ + portdb.match(x): + available = True + elif "--usepkg" in self.myopts: + mymatches = bindb.match(x) + if "--usepkgonly" not in self.myopts: + mymatches = visible(mymatches) + if mymatches: + available = True + if not available: + world_problems = True + continue + mylist.append(x) newlist = [] for atom in mylist: -- cgit v1.2.3-1-g7c22