From e612a49ef95cf9ce3d0b5496d724f73cae9aa333 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sun, 31 Oct 2021 14:17:41 +0200 Subject: Add line processing customization hook to in::rule --- libbuild2/bash/rule.cxx | 5 ++++- libbuild2/bash/rule.hxx | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'libbuild2/bash') diff --git a/libbuild2/bash/rule.cxx b/libbuild2/bash/rule.cxx index e0391e3..f2c1eae 100644 --- a/libbuild2/bash/rule.cxx +++ b/libbuild2/bash/rule.cxx @@ -200,12 +200,15 @@ namespace build2 action a, const target& t, const string& n, + optional flags, bool strict, const optional& null) const { + assert (!flags); + return n.compare (0, 6, "import") == 0 && (n[6] == ' ' || n[6] == '\t') ? substitute_import (l, a, t, trim (string (n, 7))) - : rule::substitute (l, a, t, n, strict, null); + : rule::substitute (l, a, t, n, nullopt, strict, null); } string in_rule:: diff --git a/libbuild2/bash/rule.hxx b/libbuild2/bash/rule.hxx index c54b07c..f69ac3b 100644 --- a/libbuild2/bash/rule.hxx +++ b/libbuild2/bash/rule.hxx @@ -51,6 +51,7 @@ namespace build2 action a, const target&, const string&, + optional, bool, const optional&) const override; -- cgit v1.1