diff options
author | Zac Medico <zmedico@gentoo.org> | 2007-09-06 17:10:29 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2007-09-06 17:10:29 +0000 |
commit | b379ee18087283d8b30e528911714a2037aa42f4 (patch) | |
tree | f07280cc2ebb17a86d7853d22c8dcbf87f0bbf1b | |
parent | d4bbd3e2a079e9577fadacbb67ce312b2b3e2a1f (diff) | |
download | portage-b379ee18087283d8b30e528911714a2037aa42f4.tar.gz portage-b379ee18087283d8b30e528911714a2037aa42f4.tar.bz2 portage-b379ee18087283d8b30e528911714a2037aa42f4.zip |
Move blocker handling from depgraph.create() to select_dep(). (trunk r7701)
svn path=/main/branches/2.1.2/; revision=7733
-rwxr-xr-x | bin/emerge | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/bin/emerge b/bin/emerge index fe702c583..7f61abeb1 100755 --- a/bin/emerge +++ b/bin/emerge @@ -1251,16 +1251,6 @@ class depgraph: mytype, myroot, mykey = mybigkey - if mytype == "blocks": - if myparent and \ - "--buildpkgonly" not in self.myopts and \ - "--nodeps" not in self.myopts and \ - myparent not in self._slot_collision_nodes: - mybigkey[1] = myparent[1] - self.blocker_parents.setdefault( - tuple(mybigkey), set()).add(myparent) - return 1 - # select the correct /var database that we'll be checking against vardbapi = self.trees[myroot]["vartree"].dbapi portdb = self.trees[myroot]["porttree"].dbapi @@ -1802,8 +1792,17 @@ class depgraph: print "Candidates:",mymerge for x in mymerge: selected_pkg = None - if x[0]=="!": - selected_pkg = (["blocks", myroot, x[1:]], None) + if x.startswith("!"): + if "--buildpkgonly" not in self.myopts and \ + "--nodeps" not in self.myopts and \ + myparent not in self._slot_collision_nodes: + p_type, p_root, p_key, p_status = myparent + if p_type != "installed" and p_status != "merge": + # It's safe to ignore blockers from --onlydeps nodes. + continue + self.blocker_parents.setdefault( + ("blocks", p_root, x[1:]), set()).add(myparent) + continue else: #We are not processing a blocker but a normal dependency if myparent: |