1 |
Author: zmedico |
2 |
Date: 2009-02-04 04:51:33 +0000 (Wed, 04 Feb 2009) |
3 |
New Revision: 12581 |
4 |
|
5 |
Modified: |
6 |
main/trunk/pym/_emerge/__init__.py |
7 |
Log: |
8 |
Fix Scheduler._find_system_deps() so that it only traverses runtime deps. |
9 |
|
10 |
|
11 |
Modified: main/trunk/pym/_emerge/__init__.py |
12 |
=================================================================== |
13 |
--- main/trunk/pym/_emerge/__init__.py 2009-02-04 04:05:24 UTC (rev 12580) |
14 |
+++ main/trunk/pym/_emerge/__init__.py 2009-02-04 04:51:33 UTC (rev 12581) |
15 |
@@ -9991,14 +9991,21 @@ |
16 |
if system_set.findAtomForPackage(node): |
17 |
node_stack.append(node) |
18 |
|
19 |
+ def ignore_priority(priority): |
20 |
+ """ |
21 |
+ Ignore non-runtime priorities. |
22 |
+ """ |
23 |
+ if isinstance(priority, DepPriority) and \ |
24 |
+ (priority.runtime or priority.runtime_post): |
25 |
+ return False |
26 |
+ return True |
27 |
+ |
28 |
while node_stack: |
29 |
node = node_stack.pop() |
30 |
if node in deep_system_deps: |
31 |
continue |
32 |
deep_system_deps.add(node) |
33 |
- # TODO: Only traverse runtime deps since we aren't concerned about |
34 |
- # buildtime deps here. |
35 |
- for child in graph.child_nodes(node): |
36 |
+ for child in graph.child_nodes(node, ignore_priority=ignore_priority): |
37 |
if not isinstance(child, Package) or \ |
38 |
child.operation == "uninstall": |
39 |
continue |