无法通过终端安装任何东西 – apt-get -f install

当我尝试使用终端安装任何东西时,我得到了这个:

You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: gimp : Depends: libgimp2.0 (<= 2.6.12-z) but 2.8.0-1ubuntu0ppa3~precise is to be installed Depends: gimp-data (<= 2.6.12-z) but 2.8.0-1ubuntu0ppa3~precise is to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution). 

我将自己添加到了grub恢复模式的root组中。 然后做了sudo apt-get -f install并得到了这个:

 Errors were encountered while processing: /var/cache/apt/archives/gimp_2.8.0-1ubuntu0ppa3~precise_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1) 

好的,从我所知道的,你的问题是你已经添加了一个PPA来尝试升级到最新版本的GIMP,但它还没有成功。 我认为现在最好的选择是删除PPA,这样你就可以恢复安装软件的能力了。

打开Update Manager并点击Settings 。 这将带您进入软件源管理器,您可以在此处阅读更多信息。 转到“其他软件”选项卡,取消您添加的与GIMP相关的任何PPA。

然后打开一个终端,并一次输入一个这些命令(如果失败,你可能需要在sudo apt-get remove gimp之前运行第三个命令):

 sudo apt-get update sudo apt-get remove gimp sudo apt-get -f sudo apt-get upgrade 

GIMP将被卸载,但它应该让您的系统再次运行。 您还应该能够从存储库重新安装默认版本的GIMP。

试试这个:

 sudo apt-get build-dep