diff options
Diffstat (limited to 'libbuild2/prerequisite.hxx')
-rw-r--r-- | libbuild2/prerequisite.hxx | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/libbuild2/prerequisite.hxx b/libbuild2/prerequisite.hxx index 2f63056..9b9cccf 100644 --- a/libbuild2/prerequisite.hxx +++ b/libbuild2/prerequisite.hxx @@ -97,10 +97,26 @@ namespace build2 scope (s), vars (*this, false /* shared */) {} - // Make a prerequisite from a target. + prerequisite (const target_type_type& t, + dir_path d, + dir_path o, + string n, + optional<string> e, + const scope_type& s) + : type (t), + dir (move (d)), + out (move (o)), + name (move (n)), + ext (move (e)), + scope (s), + vars (*this, false /* shared */) {} + + // Make a prerequisite from a target. If the second argument is true, + // assume the targets mutex is locked (see ext_locked()/key_locked() + // for background). // explicit - prerequisite (const target_type&); + prerequisite (const target_type&, bool locked = false); // Note that the returned key "tracks" the prerequisite; that is, any // updates to the prerequisite's members will be reflected in the key. |