From ffaf9794efe344a6af27aaf3d69500bbf857559f Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sat, 19 May 2018 11:14:21 +0200 Subject: Set .booted variable for booted but not yet loaded modules --- build2/context.cxx | 11 +++++++---- build2/module.cxx | 2 ++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/build2/context.cxx b/build2/context.cxx index 95230a6..83b3cff 100644 --- a/build2/context.cxx +++ b/build2/context.cxx @@ -678,10 +678,13 @@ namespace build2 // module.cxx:load_module(). // - vp.insert_pattern ( - "**.loaded", false, variable_visibility::project); - vp.insert_pattern ( - "**.configured", false, variable_visibility::project); + { + auto v_p (variable_visibility::project); + + vp.insert_pattern ("**.booted", false, v_p); + vp.insert_pattern ("**.loaded", false, v_p); + vp.insert_pattern ("**.configured", false, v_p); + } { auto v_p (variable_visibility::project); diff --git a/build2/module.cxx b/build2/module.cxx index 9994c9b..6ff3636 100644 --- a/build2/module.cxx +++ b/build2/module.cxx @@ -48,6 +48,8 @@ namespace build2 i = lm.emplace (name, module_state {true, false, mf.init, nullptr, loc}).first; i->second.first = mf.boot (rs, loc, i->second.module); + + rs.assign (var_pool.rw (rs).insert (name + ".booted")) = true; } bool -- cgit v1.1