aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/install/rule.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'libbuild2/install/rule.cxx')
-rw-r--r--libbuild2/install/rule.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/libbuild2/install/rule.cxx b/libbuild2/install/rule.cxx
index b4b4a01..2d81067 100644
--- a/libbuild2/install/rule.cxx
+++ b/libbuild2/install/rule.cxx
@@ -289,7 +289,14 @@ namespace build2
action, const target& t, const prerequisite& p) const
{
if (p.is_a<exe> ())
- return nullptr;
+ {
+ // Feels like one day this should be unified with include (see
+ // context::var_include).
+ //
+ if (p.vars.empty () ||
+ cast_empty<path> (p.vars["install"]).string () != "true")
+ return nullptr;
+ }
const target& pt (search (t, p));
return is == nullptr || pt.in (*is) ? &pt : nullptr;