编辑:我的问题是重复的,但我在这里的答案与上面链接的答案有点不同。
由于以下错误,我无法使用APT安装、删除或升级任何内容:
$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
guvcview : Depends: libguvcview-2.0-0 but it is not installed
Recommends: uvcdynctrl but it is not installed
E: Unmet dependencies. Try using -f.我确信我能找到并修正这个错误。我更感兴趣的是,为什么整个apt会因为一个程序有问题而被破坏。
编辑:我也不能apt-get dist-upgrade:
$ sudo apt-get dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
guvcview : Depends: libguvcview-2.0-0 but it is not installed
Recommends: uvcdynctrl but it is not installed
E: Unmet dependencies. Try using -f.apt-get -f install遇到了以下错误:
Preparing to unpack .../libguvcview-2.0-0_2.0.5+ubuntu2~ppa1+1418-0ubuntu1~201702081552~ubuntu16.10.1_amd64.deb ...
Unpacking libguvcview-2.0-0:amd64 (2.0.5+ubuntu2~ppa1+1418-0ubuntu1~201702081552~ubuntu16.10.1) ...
dpkg: error processing archive /var/cache/apt/archives/libguvcview-2.0-0_2.0.5+ubuntu2~ppa1+1418-0ubuntu1~201702081552~ubuntu16.10.1_amd64.deb (--unpack):
trying to overwrite '/usr/lib/x86_64-linux-gnu/libgviewaudio-2.0.so.2.0.0', which is also in package libguvcview-2.0-2:amd64 2.0.4+debian-1
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/libguvcview-2.0-0_2.0.5+ubuntu2~ppa1+1418-0ubuntu1~201702081552~ubuntu16.10.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)应该注意的是,我的系统上不存在文件/usr/lib/x86_64-linux-gnu/libgviewaudio-2.0.so.2.0.0。
因为这个我不能用APT做任何事。我甚至不能删除一个无关的程序。abiword是一个文本编辑器。
$ sudo apt-get remove abiword
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
guvcview : Depends: libguvcview-2.0-0 but it is not going to be installed
Recommends: uvcdynctrl but it is not going to be installed
lubuntu-desktop : Depends: abiword but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).操作系统: Lubuntu桌面(Ubuntu 16.10)
发布于 2018-01-09 03:57:41
我在这里找到了答案:
apt-获取命令在libpython3.3未满足的依赖项中失败
显然,我安装了两个相互冲突的guvcview版本。
apt list --installed | grep guvc
guvcview/yakkety,now 2.0.5+ubuntu2~ppa1+1418-0ubuntu1~201702081552~ubuntu16.10.1 amd64 [installed]
libguvcview-2.0-2/yakkety,now 2.0.4+debian-1 amd64 [installed]根据上面的答案,我使用dkpg -r --force-depends删除它们:
sudo dpkg -r --force-depends guvcview
sudo dpkg -r --force-depends libguvcview-2.0-2在这一点上,我又试着像往常一样尝试apt-get upgrade:
sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
lubuntu-desktop : Depends: guvcview but it is not installed
E: Unmet dependencies. Try using -f.啊哈!这一次我收到了一条预期的错误消息。guvcview是lubuntu-desktop所依赖的软件包:这意味着如果我在删除它之后重新安装它,那么一切都应该恢复正常,对吗?
在运行这些命令之后:
sudo apt-get -f install
sudo apt-get upgrade现在一切都正常了。guvcview也再次工作,这很好,因为我在调试此错误时破坏了它。

https://askubuntu.com/questions/993756
复制相似问题