summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-10-20 00:44:52 +0000
committerZac Medico <zmedico@gentoo.org>2008-10-20 00:44:52 +0000
commit17917af467622d8c528885929009e749ed1f7bef (patch)
treeb5fbbf4957d3a7a50b24a1e181b2e5315f3c0dac /pym
parentccac2968eeb82e3198252b9604454ced4b54f1b1 (diff)
downloadportage-17917af467622d8c528885929009e749ed1f7bef.tar.gz
portage-17917af467622d8c528885929009e749ed1f7bef.tar.bz2
portage-17917af467622d8c528885929009e749ed1f7bef.zip
Revert previous 2 commits since they broke "selective" behavior.
svn path=/main/trunk/; revision=11704
Diffstat (limited to 'pym')
-rw-r--r--pym/_emerge/__init__.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py
index 9d260ebd6..03ee50eca 100644
--- a/pym/_emerge/__init__.py
+++ b/pym/_emerge/__init__.py
@@ -5417,17 +5417,20 @@ class depgraph(object):
# Therefore, "selective" logic does not consider
# whether or not an installed package matches an
# argument atom. It only considers whether or not
- # available packages match argument atoms.
+ # available packages match argument atoms, which is
+ # represented by the found_available_arg flag.
+ found_available_arg = False
for find_existing_node in True, False:
if existing_node:
break
for db, pkg_type, built, installed, db_keys in dbs:
if existing_node:
break
- if not find_existing_node and \
- installed and matched_packages and \
- (reinstall or empty or not selective):
- continue
+ if installed and not find_existing_node:
+ want_reinstall = reinstall or empty or \
+ (found_available_arg and not selective)
+ if want_reinstall and matched_packages:
+ continue
if hasattr(db, "xmatch"):
cpv_list = db.xmatch("match-all", atom)
else:
@@ -5565,6 +5568,8 @@ class depgraph(object):
if not installed:
# masked by corruption
continue
+ if not installed and myarg:
+ found_available_arg = True
if atom.use and not pkg.built:
use = pkg.use.enabled