aboutsummaryrefslogtreecommitdiff
path: root/build2/file.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2018-05-23 12:44:56 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2018-05-23 12:44:56 +0200
commit954c9ac620a3f37d45ce2aa3bd35564a519b1143 (patch)
tree33173480108c51b6a04a3f508bdb45984f8085ac /build2/file.cxx
parent437b71971053caaaa4d3e7bc406c8e0bd26e3db7 (diff)
Fix bug in inner project bootstrap during configure/disfigure
Diffstat (limited to 'build2/file.cxx')
-rw-r--r--build2/file.cxx9
1 files changed, 7 insertions, 2 deletions
diff --git a/build2/file.cxx b/build2/file.cxx
index 89c811d..3cb6980 100644
--- a/build2/file.cxx
+++ b/build2/file.cxx
@@ -940,6 +940,8 @@ namespace build2
scope&
create_bootstrap_inner (scope& root, const dir_path& out_base)
{
+ scope* r (&root);
+
if (auto l = root.vars[var_subprojects])
{
for (const auto& p: cast<subprojects> (l))
@@ -986,11 +988,14 @@ namespace build2
// See if there are more inner roots.
//
- return create_bootstrap_inner (rs, out_base);
+ r = &create_bootstrap_inner (rs, out_base);
+
+ if (!out_base.empty ())
+ break; // We have found our subproject.
}
}
- return root;
+ return *r;
}
void