diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2019-11-12 09:51:45 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2019-11-12 09:51:45 +0200 |
commit | 4551e5797fe83d4e5e31f3164fcfa3418332ac3d (patch) | |
tree | 038e0a836444e7ae3e9f68c93a7fd3f36c31865e /libbuild2 | |
parent | 45ae0f38febb82a99844df84b65ec0fec31d2918 (diff) |
Rename config.module to config.config.module
The old name was an accidental land-grab.
Diffstat (limited to 'libbuild2')
-rw-r--r-- | libbuild2/config/functions.cxx | 4 | ||||
-rw-r--r-- | libbuild2/config/init.cxx | 20 |
2 files changed, 12 insertions, 12 deletions
diff --git a/libbuild2/config/functions.cxx b/libbuild2/config/functions.cxx index b6ccb74..ec4af65 100644 --- a/libbuild2/config/functions.cxx +++ b/libbuild2/config/functions.cxx @@ -25,8 +25,8 @@ namespace build2 // config.export variable functionality. // // Note that this function can only be used during configure unless the - // config module creation was forced for other meta-operations with - // config.module=true in bootstrap.build. + // config module creation was requested for other meta-operations with + // config.config.module=true in bootstrap.build. // f[".export"] = [] (const scope* s) { diff --git a/libbuild2/config/init.cxx b/libbuild2/config/init.cxx index e1c1dd0..1775a52 100644 --- a/libbuild2/config/init.cxx +++ b/libbuild2/config/init.cxx @@ -38,6 +38,13 @@ namespace build2 l5 ([&]{trace << "for " << rs;}); + // Note that the config.<name>* variables belong to the module <name>. + // So the only "special" variables we can allocate in config.* are + // config.config.*, names that have been "gifted" to us by other modules + // (like config.version below) as well as names that we have reserved to + // not be valid module names (`build`). We also currently treat `import` + // as special. + // auto& vp (rs.ctx.var_pool.rw (rs)); // While config.import could theoretically be specified in a buildfile, @@ -51,13 +58,13 @@ namespace build2 vp.insert<paths> ("config.import", true /* ovr */); // Only create the module if we are configuring or creating or if it was - // forced with config.module (useful if we need to call $config.export() - // during other meta-operations). + // requested with config.config.module (useful if we need to call + // $config.export() during other meta-operations). // // Detecting the former (configuring/creating) is a bit tricky since the // build2 core may not yet know if this is the case. But we know. // - auto& c_m (vp.insert<bool> ("config.module", false /*ovr*/)); + auto& c_m (vp.insert<bool> ("config.config.module", false /*ovr*/)); const string& mname (ctx.current_mname); const string& oname (ctx.current_oname); @@ -116,14 +123,7 @@ namespace build2 assert (config_hints.empty ()); // We don't known any hints. - // Note that the config.<name>* variables belong to the module <name>. - // So the only "special" variables we can allocate in config.* are - // config.config.*, names that have been "gifted" to us by other modules - // (like config.version) as well as names that we have reserved to not - // be valid module names (build, import, export). - // auto& vp (rs.ctx.var_pool.rw (rs)); - auto& c_v (vp.insert<uint64_t> ("config.version", false /*ovr*/)); // Load config.build if one exists followed by extra files specified in |