aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/search.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2019-08-22 14:38:57 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2019-08-23 18:14:07 +0200
commit5035f4ef68922ac758b1e4734e67d73c9228010b (patch)
tree271fdd5b1d6e995a058d97aacb3ac90a538d9ff1 /libbuild2/search.hxx
parent8793941652d6aa1c3d02b2f87f691e6d06254b7d (diff)
Introduce notion of build context
All non-const global state is now in class context and we can now have multiple independent builds going on at the same time.
Diffstat (limited to 'libbuild2/search.hxx')
-rw-r--r--libbuild2/search.hxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/libbuild2/search.hxx b/libbuild2/search.hxx
index b281b12..63ea6b1 100644
--- a/libbuild2/search.hxx
+++ b/libbuild2/search.hxx
@@ -13,12 +13,14 @@
namespace build2
{
class target;
+ class context;
class prerequisite_key;
- // Search for an existing target in this prerequisite's scope.
+ // Search for an existing target in this prerequisite's scope. Scope can be
+ // NULL if directories are absolute.
//
LIBBUILD2_SYMEXPORT const target*
- search_existing_target (const prerequisite_key&);
+ search_existing_target (context&, const prerequisite_key&);
// Search for an existing file. If the prerequisite directory is relative,
// then look in the scope's src directory. Otherwise, if the absolute
@@ -30,12 +32,12 @@ namespace build2
// contains the search paths. But there wasn't any need for this yet.
//
LIBBUILD2_SYMEXPORT const target*
- search_existing_file (const prerequisite_key&);
+ search_existing_file (context&, const prerequisite_key&);
// Create a new target in this prerequisite's scope.
//
LIBBUILD2_SYMEXPORT const target&
- create_new_target (const prerequisite_key&);
+ create_new_target (context&, const prerequisite_key&);
}
#endif // LIBBUILD2_SEARCH_HXX