aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/adhoc-rule-cxx.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2021-03-26 16:03:29 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2021-04-02 12:07:38 +0200
commitb3bc26dc284cf73e97b88c9979d49368d07e686c (patch)
tree59ab65ede17e84b2fa463a4d27eaaa92fd0f8b85 /libbuild2/adhoc-rule-cxx.cxx
parent5f768f4f3e6e9e1b7310a0e8b09a97bf6d0115ea (diff)
Add support for propagating project environment
Diffstat (limited to 'libbuild2/adhoc-rule-cxx.cxx')
-rw-r--r--libbuild2/adhoc-rule-cxx.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/libbuild2/adhoc-rule-cxx.cxx b/libbuild2/adhoc-rule-cxx.cxx
index 4bf67f0..92af269 100644
--- a/libbuild2/adhoc-rule-cxx.cxx
+++ b/libbuild2/adhoc-rule-cxx.cxx
@@ -291,8 +291,10 @@ namespace build2
create_module_context (ctx, loc);
}
- // "Switch" to the module context.
+ // Clear current project's environment and "switch" to the module
+ // context.
//
+ auto_thread_env penv (nullptr);
context& ctx (*t.ctx.module_context);
// Mark the queue so that we don't work any tasks that may already be