做的时候
$ sudo apt-get install vim
我有 :
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:
vim : Depends: vim-common (= 2:7.3.154+hg~74503f6ee649-2ubuntu2) but 2:7.3.154+hg~74503f6ee649-2ubuntu3 is to be installed
E: Unable to correct problems, you have held broken packages.
为了解决这个问题,我做了:
sudo apt-get remove vim-common
sudo apt-get clean && sudo apt-get purge
sudo apt-get update && sudo apt-get install vim
我必须说,先前的修复是vim安装的窍门,但不是其他仍然给我同样问题的软件包(E:无法纠正问题,您拿着损坏的软件包)
搜索更多之后,我在另一个论坛上发现了一个更好的解决方案。该修复程序已由Liam Proven提供(http://ubuntu.5.n6.nabble.com/E-Unable-to-correct-problems-you-have-held-broken-packages-td4355181.html)。
在Synaptic(如果已安装)或系统设置| 软件来源。寻找选择以找到最快的服务器。它通常会在您附近拾起一面轻载的镜子。
设置最快的服务器后,我没有任何问题。希望是有用的。