diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2023-02-01 11:42:31 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2023-02-01 11:42:31 +0200 |
commit | 546391dab6173660acceba6404136e9411ce1388 (patch) | |
tree | 79da333fd1f7447c6b9490565f520d1d79a329b7 /bpkg/system-repository.hxx | |
parent | 724131b7e03934664621f86df2dc2285ff43dba8 (diff) |
Implement system package manager query and install support for Debian
Diffstat (limited to 'bpkg/system-repository.hxx')
-rw-r--r-- | bpkg/system-repository.hxx | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/bpkg/system-repository.hxx b/bpkg/system-repository.hxx index f33d622..31e14d1 100644 --- a/bpkg/system-repository.hxx +++ b/bpkg/system-repository.hxx @@ -12,6 +12,8 @@ #include <bpkg/types.hxx> #include <bpkg/utility.hxx> +#include <bpkg/system-package-manager.hxx> + namespace bpkg { // A map of discovered system package versions. The information can be @@ -30,16 +32,25 @@ namespace bpkg version_type version; bool authoritative; + + // If the information is authoritative then this member indicates whether + // the version came from the system package manager (not NULL) or + // user/fallback (NULL). + // + const system_package_status* system_status; }; class system_repository { public: const version& - insert (const package_name& name, const version&, bool authoritative); + insert (const package_name& name, + const version&, + bool authoritative, + const system_package_status* = nullptr); const system_package* - find (const package_name& name) + find (const package_name& name) const { auto i (map_.find (name)); return i != map_.end () ? &i->second : nullptr; |