aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/build
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2022-06-24 10:29:09 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2022-06-24 10:29:09 +0200
commitf1c981a22365411794806ed0744b857ef0804e35 (patch)
treeaf453c932bfa597a04dc7af17d5f5720f863d081 /libbuild2/build
parent1c12242aa7cd00e35a9be43b664e5486b2adc846 (diff)
Allow ad hoc rules not to list targets that are updated during match
For example, this allows a Qt moc rule not to list generated headers from libQtCore since they are pre-generated by the library.
Diffstat (limited to 'libbuild2/build')
-rw-r--r--libbuild2/build/script/parser.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/libbuild2/build/script/parser.cxx b/libbuild2/build/script/parser.cxx
index 9f04102..795dc72 100644
--- a/libbuild2/build/script/parser.cxx
+++ b/libbuild2/build/script/parser.cxx
@@ -15,6 +15,8 @@
#include <libbuild2/algorithm.hxx>
#include <libbuild2/make-parser.hxx>
+#include <libbuild2/adhoc-rule-buildscript.hxx>
+
#include <libbuild2/script/run.hxx>
#include <libbuild2/build/script/lexer.hxx>
@@ -1632,7 +1634,7 @@ namespace build2
// So there is a nuanced interaction between update=match and
// --update-*.
//
- if ((p.include & 4) != 0)
+ if ((p.include & adhoc_buildscript_rule::include_unmatch) != 0)
{
l6 ([&]{trace << "skipping unmatched " << *pt;});
continue;
@@ -1705,6 +1707,11 @@ namespace build2
update = dyndep::update (
trace, a, *pt, update ? timestamp_unknown : mt) || update;
+ // While implicit, it is for a static prerequisite, so marking it
+ // feels correct.
+ //
+ p.include |= prerequisite_target::include_udm;
+
// Mark as updated (see execute_update_prerequisites() for
// details.
//