summaryrefslogtreecommitdiffstats
path: root/apt-private/private-cmndline.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-14 19:18:39 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-14 19:18:39 +0000
commit55158daa5b13e2f61658a1678288e5848bd2927a (patch)
tree551ec3d16791c4f72e6b7b403094459e7466a548 /apt-private/private-cmndline.cc
parentReleasing progress-linux version 2.9.2-0.0~progress7.99u1. (diff)
downloadapt-55158daa5b13e2f61658a1678288e5848bd2927a.tar.xz
apt-55158daa5b13e2f61658a1678288e5848bd2927a.zip
Merging upstream version 2.9.3.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--apt-private/private-cmndline.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/apt-private/private-cmndline.cc b/apt-private/private-cmndline.cc
index b05ec89..592ebd9 100644
--- a/apt-private/private-cmndline.cc
+++ b/apt-private/private-cmndline.cc
@@ -190,6 +190,7 @@ static bool addArgumentsAPTGet(std::vector<CommandLine::Args> &Args, char const
addArg(0, "auto-remove", "APT::Get::AutomaticRemove", 0);
addArg(0, "reinstall", "APT::Get::ReInstall", 0);
addArg(0, "solver", "APT::Solver", CommandLine::HasArg);
+ addArg(0, "strict-pinning", "APT::Solver::Strict-Pinning", 0);
addArg(0, "planner", "APT::Planner", CommandLine::HasArg);
addArg('U', "update", "APT::Update", 0);
if (CmdMatches("upgrade"))
@@ -230,6 +231,7 @@ static bool addArgumentsAPTGet(std::vector<CommandLine::Args> &Args, char const
addArg('P', "build-profiles", "APT::Build-Profiles", CommandLine::HasArg);
addArg(0, "purge", "APT::Get::Purge", 0);
addArg(0, "solver", "APT::Solver", CommandLine::HasArg);
+ addArg(0, "strict-pinning", "APT::Solver::Strict-Pinning", 0);
if (CmdMatches("build-dep"))
{
addArg(0,"arch-only","APT::Get::Arch-Only",0);
@@ -580,6 +582,12 @@ std::vector<CommandLine::Dispatch> ParseCommandLine(CommandLine &CmdL, APT_CMD c
_error->Warning(_("--force-yes is deprecated, use one of the options starting with --allow instead."));
}
+ if (not _config->FindB("APT::Solver::Strict-Pinning", true) && _config->Find("APT::Solver", "internal") == "internal")
+ {
+ _config->Set("APT::Solver", "3.0");
+ _error->Notice("Automatically enabled --solver 3.0 for --no-strict-pinning");
+ }
+
// See if the help should be shown
if (_config->FindB("help") == true || _config->FindB("version") == true ||
(CmdL.FileSize() > 0 && strcmp(CmdL.FileList[0], "help") == 0))