diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-14 19:18:39 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-14 19:18:39 +0000 |
commit | 6b271185e965779bc07e68383204992b21f675e7 (patch) | |
tree | b9f50ef851c4be5fa076284b72500dc70a7d2d5b /apt-pkg/edsp.cc | |
parent | Adding debian version 2.9.2. (diff) | |
download | apt-6b271185e965779bc07e68383204992b21f675e7.tar.xz apt-6b271185e965779bc07e68383204992b21f675e7.zip |
Merging upstream version 2.9.3.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'apt-pkg/edsp.cc')
-rw-r--r-- | apt-pkg/edsp.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/apt-pkg/edsp.cc b/apt-pkg/edsp.cc index a02e400..5894008 100644 --- a/apt-pkg/edsp.cc +++ b/apt-pkg/edsp.cc @@ -19,6 +19,7 @@ #include <apt-pkg/pkgsystem.h> #include <apt-pkg/prettyprinters.h> #include <apt-pkg/progress.h> +#include <apt-pkg/solver3.h> #include <apt-pkg/string_view.h> #include <apt-pkg/strutl.h> #include <apt-pkg/tagfile.h> @@ -765,6 +766,18 @@ static bool CreateDumpFile(char const * const id, char const * const type, FileF // EDSP::ResolveExternal - resolve problems by asking external for help {{{*/ bool EDSP::ResolveExternal(const char* const solver, pkgDepCache &Cache, unsigned int const flags, OpProgress *Progress) { + if (strcmp(solver, "3.0") == 0) + { + APT::Solver s(Cache.GetCache(), Cache.GetPolicy()); + FileFd output; + if (not s.FromDepCache(Cache)) + return false; + if (not s.Solve()) + return false; + if (not s.ToDepCache(Cache)) + return false; + return true; + } if (strcmp(solver, "internal") == 0) { FileFd output; |