diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2023-07-28 22:04:29 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2023-07-31 19:35:21 +0300 |
commit | 67d42b48930f65a7e270e153f1ca627c5241d17b (patch) | |
tree | 817d36b4718793b6475cfdf59fd1ffe2d0b9e344 /bpkg/package-query.hxx | |
parent | da6d239d0771142b795d18105aac8d130e85c5ba (diff) |
Fix unexpected 'no package available for dependency' error when building from archives (GH issue #303)
Diffstat (limited to 'bpkg/package-query.hxx')
-rw-r--r-- | bpkg/package-query.hxx | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/bpkg/package-query.hxx b/bpkg/package-query.hxx index 12456ce..be4e0be 100644 --- a/bpkg/package-query.hxx +++ b/bpkg/package-query.hxx @@ -226,6 +226,25 @@ namespace bpkg shared_ptr<available_package> find_imaginary_stub (const package_name&); + // Try to find an available package in the existing packages registry. Such + // a registry is configuration-specific and contains package versions + // specified by the user on the command line as archives or directories for + // specific configurations (see pkg-build for details on such packages). + // + // Note that semantically such a registry can be considered as an imaginary + // repository which complements all the real repositories fetched in the + // respective configuration. Also note that normally this repository is used + // first (by calling this function) when trying to resolve a dependency + // package, prior to searching in the real repositories. + // + extern vector<pair<reference_wrapper<database>, + shared_ptr<available_package>>> existing_packages; + + pair<shared_ptr<available_package>, lazy_shared_ptr<repository_fragment>> + find_existing (const package_name&, + const optional<version_constraint>&, + const lazy_shared_ptr<repository_fragment>&); + // Configurations to use as the repository information sources. // // The list normally contains the current configurations and configurations |