我正在尝试安装 lubuntu-desktop 包。
user@host:~$ sudo apt-get install lubuntu-desktop
失败并出现以下错误:
The following packages have unmet dependencies.
lubuntu-desktop : Depends: gdebi but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
所以我继续
user@host:~$ sudo apt-get install gdebi
导致
The following packages have unmet dependencies.
gdebi : Depends: gdebi-core (= 0.9.5.3ubuntu2) but 0.9.5.3ubuntu1 is to be installed
Recommends: libgtk2-perl but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
因此我继续获取这个 libgtk2--perl 包,然后尝试再次安装 gdebi,结果如下:
user@host:~$ sudo apt-get install gdebi
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.
gdebi : Depends: gdebi-core (= 0.9.5.3ubuntu2) but 0.9.5.3ubuntu1 is to be installed
E: Unable to correct problems, you have held broken packages.
但主要是,出了什么问题,我该如何纠正它?
编辑:添加所需信息
广东德比信息技术有限公司
user@host:~$ sudo apt-cache policy gdebi
gdebi:
Installed: (none)
Candidate: 0.9.5.3ubuntu2
Version table:
0.9.5.3ubuntu2 0
500 http://it.archive.ubuntu.com/ubuntu/ trusty-proposed/universe amd64 Packages
0.9.5.3ubuntu1 0
500 http://it.archive.ubuntu.com/ubuntu/ trusty-updates/universe amd64 Packages
0.9.5.3 0
500 http://it.archive.ubuntu.com/ubuntu/ trusty/universe amd64 Packages
GDEBI核心
user@host:~$ sudo apt-cache policy gdebi-core
gdebi-core:
Installed: 0.9.5.3ubuntu1
Candidate: 0.9.5.3ubuntu1
Version table:
*** 0.9.5.3ubuntu1 0
500 http://it.archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
100 /var/lib/dpkg/status
0.9.5.3 0
500 http://it.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
答案1
我也遇到过这种情况。我没有尝试过 enedil 的解决方案,但我尝试sudo apt install lubuntu-core
过然后 sudo apt install lubuntu-desktop
。我知道这个问题已经解决了,但我认为这可能是另一种解决方案。
答案2
执行完整的系统更新并重试:
sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade