aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-06-23 13:38:20 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-06-23 13:38:20 +0100
commit33fa0d8db9579cf790250d530157dfd9f53b88fc (patch)
treec157cb183bf0babbc51c1333ed3795b3409b9739
parent98720c3fccbdf3ef64c7dd2d7f88039f287e3f7d (diff)
downloadpaludis-33fa0d8db9579cf790250d530157dfd9f53b88fc.tar.gz
paludis-33fa0d8db9579cf790250d530157dfd9f53b88fc.tar.xz
Only care about taken changing things
-rw-r--r--paludis/resolver/decider.cc14
1 files changed, 9 insertions, 5 deletions
diff --git a/paludis/resolver/decider.cc b/paludis/resolver/decider.cc
index 54fa172..cf5d152 100644
--- a/paludis/resolver/decider.cc
+++ b/paludis/resolver/decider.cc
@@ -346,7 +346,7 @@ Decider::_collect_changing() const
for (ResolutionsByResolvent::ConstIterator i(_imp->resolutions_by_resolvent->begin()),
i_end(_imp->resolutions_by_resolvent->end()) ;
i != i_end ; ++i)
- if ((*i)->decision())
+ if ((*i)->decision() && (*i)->decision()->taken())
(*i)->decision()->accept(c);
return std::make_pair(c.going_away, c.newly_available);
@@ -1862,9 +1862,7 @@ Decider::_resolve_purges()
std::set_difference(newly_unused->begin(), newly_unused->end(),
used_by_unchanging->begin(), used_by_unchanging->end(), newly_really_unused->inserter(), PackageIDSetComparator());
- if (newly_really_unused->empty())
- return false;
-
+ bool changed(false);
for (PackageIDSet::ConstIterator i(newly_really_unused->begin()), i_end(newly_really_unused->end()) ;
i != i_end ; ++i)
{
@@ -1877,13 +1875,19 @@ Decider::_resolve_purges()
Resolvent resolvent(*i, dt_install_to_slash);
const std::tr1::shared_ptr<Resolution> resolution(_resolution_for_resolvent(resolvent, true));
+
+ if (resolution->decision())
+ continue;
+
const std::tr1::shared_ptr<const ConstraintSequence> constraints(_make_constraints_for_purge(resolution, *i, used_to_use));
for (ConstraintSequence::ConstIterator c(constraints->begin()), c_end(constraints->end()) ;
c != c_end ; ++c)
_apply_resolution_constraint(resolution, *c);
+
+ changed = true;
}
- return true;
+ return changed;
}
const std::tr1::shared_ptr<const PackageIDSet>