![由于未满足依赖关系,无法在 Debian 7 中安装语言环境](https://linux22.com/image/55687/%E7%94%B1%E4%BA%8E%E6%9C%AA%E6%BB%A1%E8%B6%B3%E4%BE%9D%E8%B5%96%E5%85%B3%E7%B3%BB%EF%BC%8C%E6%97%A0%E6%B3%95%E5%9C%A8%20Debian%207%20%E4%B8%AD%E5%AE%89%E8%A3%85%E8%AF%AD%E8%A8%80%E7%8E%AF%E5%A2%83.png)
因此,我没有在我的sources.list中包含wheezy-backport,而是直接添加jessie。意识到我的错误,我中途退出了 apt-get update/upgrade,然后将sources.list重置为喘息并运行这命令列表。但是当我尝试发生sudo apt-get install locales
这种情况时:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
base-files : PreDepends: awk
erlang-crypto : Depends: libssl1.0.0 (>= 1.0.0) but it is not going to be installed
libc6 : Depends: libgcc1 but it is not going to be installed
Recommends: libc6-i686 but it is not going to be installed
Breaks: locales (< 2.19)
libncurses5 : PreDepends: multiarch-support but it is not going to be installed
Recommends: libgpm2 but it is not going to be installed
libtinfo5 : PreDepends: multiarch-support but it is not going to be installed
locales : Depends: glibc-2.13-1
Depends: debconf (>= 0.5) but it is not going to be installed or
debconf-2.0
procps : Depends: libncursesw5 (>= 5.6+20070908) but it is not going to be installed
Depends: libprocps0 (>= 1:3.3.2-1) but it is not going to be installed
Depends: initscripts but it is not going to be installed
Recommends: psmisc but it is not going to be installed
zlib1g : PreDepends: multiarch-support but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
如何解决这些依赖关系?
答案1
成功安装的最佳方法是检查缺少的依赖项;
a) 在 ubuntu 网站上找到它们并正确安装。 b) 尝试运行原来的 apt-get install {package} 命令。
如果您尝试“sudo apt-get -f install”,它会导致问题,因为它首先是强制安装的,并且将来最终会适得其反。