aboutsummaryrefslogtreecommitdiff
path: root/build/dist
diff options
context:
space:
mode:
Diffstat (limited to 'build/dist')
-rw-r--r--build/dist/module3
-rw-r--r--build/dist/module.cxx21
2 files changed, 16 insertions, 8 deletions
diff --git a/build/dist/module b/build/dist/module
index 20082ec..f2e024a 100644
--- a/build/dist/module
+++ b/build/dist/module
@@ -14,6 +14,9 @@ namespace build
{
namespace dist
{
+ extern "C" void
+ dist_boot (scope&, const location&, unique_ptr<module>&);
+
extern "C" bool
dist_init (
scope&, scope&, const location&, unique_ptr<module>&, bool, bool);
diff --git a/build/dist/module.cxx b/build/dist/module.cxx
index f0a446b..f39ef18 100644
--- a/build/dist/module.cxx
+++ b/build/dist/module.cxx
@@ -22,9 +22,21 @@ namespace build
{
static rule rule_;
+ extern "C" void
+ dist_boot (scope& r, const location&, unique_ptr<module>&)
+ {
+ tracer trace ("dist::boot");
+
+ level5 ([&]{trace << "for " << r.out_path ();});
+
+ // Register meta-operation.
+ //
+ r.meta_operations.insert (dist_id, dist);
+ }
+
extern "C" bool
dist_init (scope& r,
- scope& b,
+ scope&,
const location& l,
unique_ptr<module>&,
bool first,
@@ -32,9 +44,6 @@ namespace build
{
tracer trace ("dist::init");
- if (&r != &b)
- fail (l) << "dist module must be initialized in bootstrap.build";
-
if (!first)
{
warn (l) << "multiple dist module initializations";
@@ -66,10 +75,6 @@ namespace build
v.find ("config.dist.archives", strings_type);
}
- // Register meta-operation.
- //
- r.meta_operations.insert (dist_id, dist);
-
// Register our wildcard rule. Do it explicitly for the alias
// to prevent something like insert<target>(dist_id, test_id)
// taking precedence.