aboutsummaryrefslogtreecommitdiff
path: root/build2
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2022-06-21 10:04:07 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2022-06-21 10:04:07 +0200
commitbbe8cbd13c40a1309e0d7724319c5487a5df0879 (patch)
treebdd1e00d9605ec7d5d3d99f44f7eafaf7249a64c /build2
parent2f29c7fbe758ffb53e4de9983df8b1cc927dad05 (diff)
Add --trace-{match,execute} options
These options can be used to understand which dependency chain causes matching or execution of a particular target.
Diffstat (limited to 'build2')
-rw-r--r--build2/b.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/build2/b.cxx b/build2/b.cxx
index 470aade..f666b86 100644
--- a/build2/b.cxx
+++ b/build2/b.cxx
@@ -436,6 +436,12 @@ main (int argc, char* argv[])
ops.dry_run (),
!ops.serial_stop () /* keep_going */,
cmdl.cmd_vars));
+
+ if (ops.trace_match_specified ())
+ pctx->trace_match = &ops.trace_match ();
+
+ if (ops.trace_execute_specified ())
+ pctx->trace_execute = &ops.trace_execute ();
};
new_context ();