aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--paludis/resolver/orderer.cc11
-rw-r--r--paludis/resolver/resolved.cc3
-rw-r--r--paludis/resolver/resolved.hh2
-rw-r--r--paludis/resolver/resolver.cc1
-rw-r--r--paludis/resolver/resolver_TEST_any.cc8
-rw-r--r--paludis/resolver/resolver_TEST_blockers.cc31
-rw-r--r--paludis/resolver/resolver_TEST_continue_on_failure.cc2
-rw-r--r--paludis/resolver/resolver_TEST_cycles.cc51
-rw-r--r--paludis/resolver/resolver_TEST_errors.cc2
-rw-r--r--paludis/resolver/resolver_TEST_serialisation.cc2
-rw-r--r--paludis/resolver/resolver_TEST_simple.cc8
-rw-r--r--paludis/resolver/resolver_TEST_suggestions.cc6
-rw-r--r--paludis/resolver/resolver_TEST_uninstalls.cc6
-rw-r--r--paludis/resolver/resolver_TEST_virtuals.cc4
-rw-r--r--paludis/resolver/resolver_test.cc6
-rw-r--r--paludis/resolver/resolver_test.hh1
-rw-r--r--src/clients/cave/cmd_display_resolution.cc23
-rw-r--r--src/clients/cave/resolve_common.cc5
18 files changed, 153 insertions, 19 deletions
diff --git a/paludis/resolver/orderer.cc b/paludis/resolver/orderer.cc
index 76c4507..7b4f20b 100644
--- a/paludis/resolver/orderer.cc
+++ b/paludis/resolver/orderer.cc
@@ -502,10 +502,13 @@ Orderer::_order_sub_ssccs(
}
else
{
- /* all that effort was wasted. there's incest and there's nothing we
- * can do to fix it. */
- throw InternalError(PALUDIS_HERE, "circular dependencies we're not smart enough to solve yet: { "
- + join(sub_scc->nodes()->begin(), sub_scc->nodes()->end(), ", ", nice_resolvent) + " }");
+ for (Set<Resolvent>::ConstIterator r(sub_scc->nodes()->begin()), r_end(sub_scc->nodes()->end()) ;
+ r != r_end ; ++r)
+ _imp->resolved->taken_unorderable_decisions()->push_back(
+ _imp->change_or_remove_resolvents.find(*r)->second,
+ make_shared_copy(make_named_values<OrdererNotes>(
+ n::cycle_breaking() = "In unsolvable cycle with " + join(
+ top_scc.nodes()->begin(), top_scc.nodes()->end(), ", ", nice_resolvent))));
}
}
}
diff --git a/paludis/resolver/resolved.cc b/paludis/resolver/resolved.cc
index f443668..80e5152 100644
--- a/paludis/resolver/resolved.cc
+++ b/paludis/resolver/resolved.cc
@@ -39,6 +39,7 @@ Resolved::serialise(Serialiser & s) const
.member(SerialiserFlags<serialise::might_be_null>(), "taken_change_or_remove_decisions", taken_change_or_remove_decisions())
.member(SerialiserFlags<serialise::might_be_null>(), "taken_unable_to_make_decisions", taken_unable_to_make_decisions())
.member(SerialiserFlags<serialise::might_be_null>(), "taken_unconfirmed_decisions", taken_unconfirmed_decisions())
+ .member(SerialiserFlags<serialise::might_be_null>(), "taken_unorderable_decisions", taken_unorderable_decisions())
.member(SerialiserFlags<serialise::might_be_null>(), "untaken_change_or_remove_decisions", untaken_change_or_remove_decisions())
.member(SerialiserFlags<serialise::might_be_null>(), "untaken_unable_to_make_decisions", untaken_unable_to_make_decisions())
;
@@ -62,6 +63,8 @@ Resolved::deserialise(Deserialisation & d)
v.member<std::tr1::shared_ptr<Decisions<UnableToMakeDecision> > >("taken_unable_to_make_decisions"),
n::taken_unconfirmed_decisions() =
v.member<std::tr1::shared_ptr<Decisions<ConfirmableDecision> > >("taken_unconfirmed_decisions"),
+ n::taken_unorderable_decisions() =
+ v.member<std::tr1::shared_ptr<OrderedChangeOrRemoveDecisions> >("taken_unorderable_decisions"),
n::untaken_change_or_remove_decisions() =
v.member<std::tr1::shared_ptr<Decisions<ChangeOrRemoveDecision> > >("untaken_change_or_remove_decisions"),
n::untaken_unable_to_make_decisions() =
diff --git a/paludis/resolver/resolved.hh b/paludis/resolver/resolved.hh
index 191de6a..fda8c44 100644
--- a/paludis/resolver/resolved.hh
+++ b/paludis/resolver/resolved.hh
@@ -40,6 +40,7 @@ namespace paludis
typedef Name<struct taken_change_or_remove_decisions_name> taken_change_or_remove_decisions;
typedef Name<struct taken_unable_to_make_decisions_name> taken_unable_to_make_decisions;
typedef Name<struct taken_unconfirmed_decisions_name> taken_unconfirmed_decisions;
+ typedef Name<struct taken_unorderable_decisions_name> taken_unorderable_decisions;
typedef Name<struct untaken_change_or_remove_decisions_name> untaken_change_or_remove_decisions;
typedef Name<struct untaken_unable_to_make_decisions_name> untaken_unable_to_make_decisions;
}
@@ -54,6 +55,7 @@ namespace paludis
NamedValue<n::taken_change_or_remove_decisions, std::tr1::shared_ptr<OrderedChangeOrRemoveDecisions> > taken_change_or_remove_decisions;
NamedValue<n::taken_unable_to_make_decisions, std::tr1::shared_ptr<Decisions<UnableToMakeDecision> > > taken_unable_to_make_decisions;
NamedValue<n::taken_unconfirmed_decisions, std::tr1::shared_ptr<Decisions<ConfirmableDecision> > > taken_unconfirmed_decisions;
+ NamedValue<n::taken_unorderable_decisions, std::tr1::shared_ptr<OrderedChangeOrRemoveDecisions> > taken_unorderable_decisions;
NamedValue<n::untaken_change_or_remove_decisions, std::tr1::shared_ptr<Decisions<ChangeOrRemoveDecision> > > untaken_change_or_remove_decisions;
NamedValue<n::untaken_unable_to_make_decisions, std::tr1::shared_ptr<Decisions<UnableToMakeDecision> > > untaken_unable_to_make_decisions;
diff --git a/paludis/resolver/resolver.cc b/paludis/resolver/resolver.cc
index bf785bd..7e02150 100644
--- a/paludis/resolver/resolver.cc
+++ b/paludis/resolver/resolver.cc
@@ -73,6 +73,7 @@ namespace paludis
n::taken_change_or_remove_decisions() = make_shared_ptr(new OrderedChangeOrRemoveDecisions),
n::taken_unable_to_make_decisions() = make_shared_ptr(new Decisions<UnableToMakeDecision>),
n::taken_unconfirmed_decisions() = make_shared_ptr(new Decisions<ConfirmableDecision>),
+ n::taken_unorderable_decisions() = make_shared_ptr(new OrderedChangeOrRemoveDecisions),
n::untaken_change_or_remove_decisions() = make_shared_ptr(new Decisions<ChangeOrRemoveDecision>),
n::untaken_unable_to_make_decisions() = make_shared_ptr(new Decisions<UnableToMakeDecision>)
))),
diff --git a/paludis/resolver/resolver_TEST_any.cc b/paludis/resolver/resolver_TEST_any.cc
index 25730f7..ccba732 100644
--- a/paludis/resolver/resolver_TEST_any.cc
+++ b/paludis/resolver/resolver_TEST_any.cc
@@ -83,6 +83,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -112,6 +114,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -140,6 +144,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -204,6 +210,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_blockers.cc b/paludis/resolver/resolver_TEST_blockers.cc
index ef9b3b5..b64e1fe 100644
--- a/paludis/resolver/resolver_TEST_blockers.cc
+++ b/paludis/resolver/resolver_TEST_blockers.cc
@@ -90,6 +90,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -121,6 +123,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -153,6 +157,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -191,6 +197,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -231,6 +239,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -263,6 +273,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -281,7 +293,24 @@ namespace test_cases
void run()
{
- TEST_CHECK_THROWS(get_resolved("hard-block-and-dep-cycle/target"), Exception);
+ std::tr1::shared_ptr<const Resolved> resolved(get_resolved("hard-block-and-dep-cycle/target"));
+
+ check_resolved(resolved,
+ n::taken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::taken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .change(QualifiedPackageName("hard-block-and-dep-cycle/dep"))
+ .change(QualifiedPackageName("hard-block-and-dep-cycle/target"))
+ .finished()),
+ n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
+ .finished())
+ );
}
} test_hard_block_and_dep_cycle;
}
diff --git a/paludis/resolver/resolver_TEST_continue_on_failure.cc b/paludis/resolver/resolver_TEST_continue_on_failure.cc
index e301b0c..826d2a8 100644
--- a/paludis/resolver/resolver_TEST_continue_on_failure.cc
+++ b/paludis/resolver/resolver_TEST_continue_on_failure.cc
@@ -129,6 +129,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_cycles.cc b/paludis/resolver/resolver_TEST_cycles.cc
index b1db400..eeb7383 100644
--- a/paludis/resolver/resolver_TEST_cycles.cc
+++ b/paludis/resolver/resolver_TEST_cycles.cc
@@ -103,6 +103,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -132,6 +134,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -159,6 +163,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -173,7 +179,26 @@ namespace test_cases
void run()
{
- TEST_CHECK_THROWS(get_resolved("mutual-build-deps/target"), Exception);
+ std::tr1::shared_ptr<const Resolved> resolved(get_resolved("mutual-build-deps/target"));
+
+ check_resolved(resolved,
+ n::taken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
+ .change(QualifiedPackageName("mutual-build-deps/target"))
+ .finished()),
+ n::taken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .change(QualifiedPackageName("mutual-build-deps/dep-a"))
+ .change(QualifiedPackageName("mutual-build-deps/dep-b"))
+ .change(QualifiedPackageName("mutual-build-deps/dep-c"))
+ .finished()),
+ n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
+ n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
+ .finished())
+ );
}
} test_mutual_build_deps;
@@ -195,14 +220,8 @@ namespace test_cases
void run()
{
- if ((! b_installed) && (! c_installed))
- {
- TEST_CHECK_THROWS(get_resolved("triangle/target"), Exception);
- return;
- }
-
std::tr1::shared_ptr<const Resolved> resolved(get_resolved("triangle/target"));
- std::tr1::shared_ptr<DecisionChecks> checks;
+ std::tr1::shared_ptr<DecisionChecks> checks, u_checks;
if (b_installed)
{
@@ -212,6 +231,8 @@ namespace test_cases
.change(QualifiedPackageName("triangle/dep-b"))
.change(QualifiedPackageName("triangle/target"))
.finished());
+ u_checks = make_shared_copy(DecisionChecks()
+ .finished());
}
else if (c_installed)
{
@@ -221,9 +242,20 @@ namespace test_cases
.change(QualifiedPackageName("triangle/dep-c"))
.change(QualifiedPackageName("triangle/target"))
.finished());
+ u_checks = make_shared_copy(DecisionChecks()
+ .finished());
}
else
- TEST_CHECK(false);
+ {
+ checks = make_shared_copy(DecisionChecks()
+ .change(QualifiedPackageName("triangle/target"))
+ .finished());
+ u_checks = make_shared_copy(DecisionChecks()
+ .change(QualifiedPackageName("triangle/dep-a"))
+ .change(QualifiedPackageName("triangle/dep-b"))
+ .change(QualifiedPackageName("triangle/dep-c"))
+ .finished());
+ }
check_resolved(resolved,
n::taken_change_or_remove_decisions() = checks,
@@ -231,6 +263,7 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = u_checks,
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_errors.cc b/paludis/resolver/resolver_TEST_errors.cc
index c7eee35..abc8a74 100644
--- a/paludis/resolver/resolver_TEST_errors.cc
+++ b/paludis/resolver/resolver_TEST_errors.cc
@@ -83,6 +83,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_serialisation.cc b/paludis/resolver/resolver_TEST_serialisation.cc
index 9637e2b..de702c9 100644
--- a/paludis/resolver/resolver_TEST_serialisation.cc
+++ b/paludis/resolver/resolver_TEST_serialisation.cc
@@ -96,6 +96,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.change(QualifiedPackageName("serialisation/suggestion"))
.finished()),
diff --git a/paludis/resolver/resolver_TEST_simple.cc b/paludis/resolver/resolver_TEST_simple.cc
index 6361465..ad29f16 100644
--- a/paludis/resolver/resolver_TEST_simple.cc
+++ b/paludis/resolver/resolver_TEST_simple.cc
@@ -80,6 +80,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -107,6 +109,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -134,6 +138,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -161,6 +167,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_suggestions.cc b/paludis/resolver/resolver_TEST_suggestions.cc
index e20eb00..1c6dade 100644
--- a/paludis/resolver/resolver_TEST_suggestions.cc
+++ b/paludis/resolver/resolver_TEST_suggestions.cc
@@ -81,6 +81,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.change(QualifiedPackageName("suggestion/dep"))
.finished()),
@@ -106,6 +108,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -133,6 +137,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_uninstalls.cc b/paludis/resolver/resolver_TEST_uninstalls.cc
index c5b7dfd..1f71c86 100644
--- a/paludis/resolver/resolver_TEST_uninstalls.cc
+++ b/paludis/resolver/resolver_TEST_uninstalls.cc
@@ -113,6 +113,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -127,6 +129,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -142,6 +146,8 @@ namespace test_cases
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.breaking(QualifiedPackageName("breaking/dep"))
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_TEST_virtuals.cc b/paludis/resolver/resolver_TEST_virtuals.cc
index abb90de..7de7731 100644
--- a/paludis/resolver/resolver_TEST_virtuals.cc
+++ b/paludis/resolver/resolver_TEST_virtuals.cc
@@ -82,6 +82,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
@@ -106,6 +108,8 @@ namespace test_cases
.finished()),
n::taken_unconfirmed_decisions() = make_shared_copy(DecisionChecks()
.finished()),
+ n::taken_unorderable_decisions() = make_shared_copy(DecisionChecks()
+ .finished()),
n::untaken_change_or_remove_decisions() = make_shared_copy(DecisionChecks()
.finished()),
n::untaken_unable_to_make_decisions() = make_shared_copy(DecisionChecks()
diff --git a/paludis/resolver/resolver_test.cc b/paludis/resolver/resolver_test.cc
index 3b89000..f9240d8 100644
--- a/paludis/resolver/resolver_test.cc
+++ b/paludis/resolver/resolver_test.cc
@@ -455,6 +455,7 @@ ResolverTestCase::check_resolved(
const NamedValue<n::taken_change_or_remove_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & taken_change_or_remove_decisions,
const NamedValue<n::taken_unable_to_make_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & taken_unable_to_make_decisions,
const NamedValue<n::taken_unconfirmed_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & taken_unconfirmed_decisions,
+ const NamedValue<n::taken_unorderable_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & taken_unorderable_decisions,
const NamedValue<n::untaken_change_or_remove_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & untaken_change_or_remove_decisions,
const NamedValue<n::untaken_unable_to_make_decisions, const std::tr1::shared_ptr<const DecisionChecks> > & untaken_unable_to_make_decisions
)
@@ -475,6 +476,11 @@ ResolverTestCase::check_resolved(
}
{
+ TestMessageSuffix s("taken unorderable");
+ check_resolved_one(resolved->taken_unorderable_decisions(), taken_unorderable_decisions());
+ }
+
+ {
TestMessageSuffix s("untaken change or remove");
check_resolved_one(resolved->untaken_change_or_remove_decisions(), untaken_change_or_remove_decisions());
}
diff --git a/paludis/resolver/resolver_test.hh b/paludis/resolver/resolver_test.hh
index 411e752..2fc41bc 100644
--- a/paludis/resolver/resolver_test.hh
+++ b/paludis/resolver/resolver_test.hh
@@ -167,6 +167,7 @@ namespace paludis
const NamedValue<n::taken_change_or_remove_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &,
const NamedValue<n::taken_unable_to_make_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &,
const NamedValue<n::taken_unconfirmed_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &,
+ const NamedValue<n::taken_unorderable_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &,
const NamedValue<n::untaken_change_or_remove_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &,
const NamedValue<n::untaken_unable_to_make_decisions, const std::tr1::shared_ptr<const DecisionChecks> > &
);
diff --git a/src/clients/cave/cmd_display_resolution.cc b/src/clients/cave/cmd_display_resolution.cc
index 72b9d47..b504717 100644
--- a/src/clients/cave/cmd_display_resolution.cc
+++ b/src/clients/cave/cmd_display_resolution.cc
@@ -1232,7 +1232,8 @@ namespace
ChoicesToExplain & choices_to_explain,
const bool more_annotations,
const bool unconfirmed,
- const bool untaken)
+ const bool untaken,
+ const bool unorderable)
{
Context context("When displaying changes and removes:");
@@ -1240,6 +1241,8 @@ namespace
cout << "I did not take the following:" << endl << endl;
else if (unconfirmed)
cout << "I cannot proceed without being permitted to do the following:" << endl << endl;
+ else if (unorderable)
+ cout << "I cannot provide a legal ordering for the following:" << endl << endl;
else
cout << "These are the actions I will take, in order:" << endl << endl;
@@ -1278,7 +1281,18 @@ namespace
ChoicesToExplain & choices_to_explain)
{
display_a_changes_and_removes(env, resolved, resolved->taken_change_or_remove_decisions(),
- cmdline, choices_to_explain, false, false, false);
+ cmdline, choices_to_explain, false, false, false, false);
+ }
+
+ void display_unorderable_changes_and_removed(
+ const std::tr1::shared_ptr<Environment> & env,
+ const std::tr1::shared_ptr<const Resolved> & resolved,
+ const DisplayResolutionCommandLine & cmdline,
+ ChoicesToExplain & choices_to_explain)
+ {
+ if (! resolved->taken_unorderable_decisions()->empty())
+ display_a_changes_and_removes(env, resolved, resolved->taken_unorderable_decisions(),
+ cmdline, choices_to_explain, false, false, false, true);
}
void display_untaken_changes_and_removes(
@@ -1289,7 +1303,7 @@ namespace
{
if (! resolved->untaken_change_or_remove_decisions()->empty())
display_a_changes_and_removes(env, resolved, resolved->untaken_change_or_remove_decisions(),
- cmdline, choices_to_explain, true, false, true);
+ cmdline, choices_to_explain, true, false, true, false);
}
void display_an_errors(
@@ -1349,7 +1363,7 @@ namespace
ChoicesToExplain ignore_choices_to_explain;
if (! resolved->taken_unconfirmed_decisions()->empty())
display_a_changes_and_removes(env, resolved, resolved->taken_unconfirmed_decisions(),
- cmdline, ignore_choices_to_explain, true, true, false);
+ cmdline, ignore_choices_to_explain, true, true, false, false);
}
}
@@ -1393,6 +1407,7 @@ DisplayResolutionCommand::run(
ChoicesToExplain choices_to_explain;
display_changes_and_removes(env, resolved, cmdline, choices_to_explain);
+ display_unorderable_changes_and_removed(env, resolved, cmdline, choices_to_explain);
display_untaken_changes_and_removes(env, resolved, cmdline, choices_to_explain);
display_choices_to_explain(env, cmdline, choices_to_explain);
display_taken_errors(env, resolved, cmdline);
diff --git a/src/clients/cave/resolve_common.cc b/src/clients/cave/resolve_common.cc
index e640825..3881004 100644
--- a/src/clients/cave/resolve_common.cc
+++ b/src/clients/cave/resolve_common.cc
@@ -1707,7 +1707,10 @@ paludis::cave::resolve_common(
retcode |= 1;
if (! resolver->resolved()->taken_unconfirmed_decisions()->empty())
- retcode |= 3;
+ retcode |= 2;
+
+ if (! resolver->resolved()->taken_unorderable_decisions()->empty())
+ retcode |= 4;
if (0 == retcode)
return perform_resolution(env, resolver->resolved(), resolution_options,