diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2017-09-08 16:16:11 +0200 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2017-09-11 13:57:29 +0300 |
commit | ffa0839de796fbefc48bacc4777648ff19b3fee6 (patch) | |
tree | 0f493314df633b6f35f9b9db78c7163506c8eed1 /build2/install/functions.cxx | |
parent | 66e516ad81225b888469b24e726095533c4f9c4c (diff) |
Add ability to pass scope to buildfile functions, add $install.resolve()
Diffstat (limited to 'build2/install/functions.cxx')
-rw-r--r-- | build2/install/functions.cxx | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/build2/install/functions.cxx b/build2/install/functions.cxx new file mode 100644 index 0000000..b9298b2 --- /dev/null +++ b/build2/install/functions.cxx @@ -0,0 +1,27 @@ +// file : build2/install/functions.cxx -*- C++ -*- +// copyright : Copyright (c) 2014-2017 Code Synthesis Ltd +// license : MIT; see accompanying LICENSE file + +#include <build2/function.hxx> +#include <build2/variable.hxx> + +#include <build2/install/utility.hxx> + +using namespace std; + +namespace build2 +{ + namespace install + { + void + functions () + { + function_family f ("install"); + + // Resolve potentially relative install.* value to an absolute directory + // based on (other) install.* values visible from the calling scope. + // + f["resolve"] = &resolve_dir; + } + } +} |