From ae9baf01f2a9627b7f1f2dc9db349d89c992f740 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 1 Nov 2023 09:42:57 +0200 Subject: Add support for adjusting match options of post hoc prerequisites --- libbuild2/target.hxx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'libbuild2/target.hxx') diff --git a/libbuild2/target.hxx b/libbuild2/target.hxx index f537d59..83e6994 100644 --- a/libbuild2/target.hxx +++ b/libbuild2/target.hxx @@ -269,6 +269,15 @@ namespace build2 static constexpr uint64_t all_options = ~uint64_t (0); + // The list of post hoc prerequisite targets for this target. Only not + // NULL in rule::apply_posthoc() and rule::reapply() functions and only if + // there are post hoc prerequisites. Primarily useful for adjusting match + // options for post hoc prerequisites (but can also be used to blank some + // of them out). + // + vector* + posthoc_prerequisite_targets; + // Auxiliary data storage. // // A rule (whether matches or not) may use this pad to pass data between @@ -340,7 +349,8 @@ namespace build2 explicit match_extra (bool l = true, bool f = false) : locked (l), fallback (f), - cur_options (all_options), new_options (0) {} + cur_options (all_options), new_options (0), + posthoc_prerequisite_targets (nullptr) {} void reinit (bool fallback); -- cgit v1.1