+ bool MatchSrcOnly = false;
+
+ // No source package name..
+ if (Src.empty() == true)
+ Src = TmpSrc;
+ else
+ // if we have a source pkg name, make sure to only search
+ // for srcpkg names, otherwise apt gets confused if there
+ // is a binary package "pkg1" and a source package "pkg1"
+ // with the same name but that comes from different packages
+ MatchSrcOnly = true;
- if (IsMatch == true && Parse->Package() != Src)
- ioprintf(c1out, _("No source package '%s' picking '%s' instead"), Parse->Package(), Src);
+ if (IsMatch == true && Parse->Package() != Src)
+ ioprintf(c1out, _("No source package '%s' picking '%s' instead\n"), Parse->Package().c_str(), Src.c_str());
{
// We successfully installed something; skip remaining alternatives
skipAlternatives = hasAlternatives;
{
// We successfully installed something; skip remaining alternatives
skipAlternatives = hasAlternatives;
" install - Install new packages (pkg is libc6 not libc6.deb)\n"
" remove - Remove packages\n"
" autoremove - Remove automatically all unused packages\n"
" install - Install new packages (pkg is libc6 not libc6.deb)\n"
" remove - Remove packages\n"
" autoremove - Remove automatically all unused packages\n"
" source - Download source archives\n"
" build-dep - Configure build-dependencies for source packages\n"
" dist-upgrade - Distribution upgrade, see apt-get(8)\n"
" source - Download source archives\n"
" build-dep - Configure build-dependencies for source packages\n"
" dist-upgrade - Distribution upgrade, see apt-get(8)\n"
{0,"only-source","APT::Get::Only-Source",0},
{0,"arch-only","APT::Get::Arch-Only",0},
{0,"auto-remove","APT::Get::AutomaticRemove",0},
{0,"only-source","APT::Get::Only-Source",0},
{0,"arch-only","APT::Get::Arch-Only",0},
{0,"auto-remove","APT::Get::AutomaticRemove",0},
{0,"allow-unauthenticated","APT::Get::AllowUnauthenticated",0},
{0,"install-recommends","APT::Install-Recommends",CommandLine::Boolean},
{0,"fix-policy","APT::Get::Fix-Policy-Broken",0},
{0,"allow-unauthenticated","APT::Get::AllowUnauthenticated",0},
{0,"install-recommends","APT::Install-Recommends",CommandLine::Boolean},
{0,"fix-policy","APT::Get::Fix-Policy-Broken",0},
{"dist-upgrade",&DoDistUpgrade},
{"dselect-upgrade",&DoDSelectUpgrade},
{"build-dep",&DoBuildDep},
{"dist-upgrade",&DoDistUpgrade},
{"dselect-upgrade",&DoDSelectUpgrade},
{"build-dep",&DoBuildDep},