aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2023-11-16 12:07:47 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2023-11-17 17:10:48 +0300
commit789f4c5666fed11bbc6d95ff537872df49134ebc (patch)
tree95511ad48fe14c42b0eb72bfee8db9c5e5e18d24
parentd84cd60c19179562bb8d5555cecb73e85f1181a9 (diff)
Re-link private configurations before failing due to presence of unsatisfied dependents
-rw-r--r--bpkg/pkg-build.cxx18
1 files changed, 10 insertions, 8 deletions
diff --git a/bpkg/pkg-build.cxx b/bpkg/pkg-build.cxx
index 5844397..c1dd312 100644
--- a/bpkg/pkg-build.cxx
+++ b/bpkg/pkg-build.cxx
@@ -4204,8 +4204,10 @@ namespace bpkg
scratch_exe = false;
}
- else if (scratch_col)
+ else
{
+ assert (scratch_col); // See the scratch definition above.
+
// Reset to detect bogus entries.
//
for (auto& rv: replaced_vers)
@@ -5330,13 +5332,6 @@ namespace bpkg
}
}
- // Issue diagnostics and fail if the execution plan is finalized and
- // any existing dependents are not satisfied with their
- // dependencies.
- //
- if (!refine && !unsatisfied_depts.empty ())
- unsatisfied_depts.diag (pkgs);
-
// Re-link the private configurations that were created during the
// collection of the package builds with their parent
// configurations. Note that these links were lost on the previous
@@ -5351,6 +5346,13 @@ namespace bpkg
t.commit ();
}
+
+ // Issue diagnostics and fail if the execution plan is finalized and
+ // any existing dependents are not satisfied with their
+ // dependencies.
+ //
+ if (!refine && !unsatisfied_depts.empty ())
+ unsatisfied_depts.diag (pkgs);
}
}