葡萄酒:取决于wine1.6或wine1.8,但它不会被安装,你已经破坏了包裹

我想在Ubuntu 16.04上安装wine,但是我收到了错误:

$ sudo apt-get install wine 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: wine : Depends: wine1.6 or wine1.8 but it is not going to be installed E: Unable to correct problems, you have held broken packages. 

还试过这个:

 $ sudo apt-get install -f Reading package lists... Done Building dependency tree Reading state information... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 

我按照无法解决问题的答案,你已经破坏了包并运行了以下命令。

 dpkg --get-selections | grep hold 

但是没有输出。

之后我还尝试了dpkg --get-selections来查看所有包。 有些人使用“deinstall”,所以我运行了以下内容:

 $ dpkg --get-selections | grep deinstall ca-certificates-mono deinstall libevent-2.0-5:amd64 deinstall libgdata2.1-cil deinstall libglib2.0-cil deinstall libgtk2.0-cil deinstall libmx-1.0-2:amd64 deinstall libnewtonsoft-json5.0-cil deinstall mono-runtime-common deinstall nvidia-304 deinstall nvidia-opencl-icd-304 deinstall tlp deinstall tlp-rdw deinstall transmission-gtk deinstall xserver-xorg-legacy deinstall 

但是这些软件包无法卸载。 我还尝试了在添加PPA后如何解决未满足的依赖关系的答案? 而这一个,但它没有解决任何问题。

我也试过使用Aptitude,但问题仍然是一样的。

我也尝试过使用Synaptic包管理器。 它也无法解决依赖关系。

无法应用更改,先修复损坏的包

我也尝试了以下命令:

 sudo aptitude -f install wine sudo apt-get dist-upgrade sudo apt-get update dpkg --get-selections | grep hold dpkg --get-selections dpkg --get-selections | grep deinstall sudo apt-get clean sudo apt-get autoclean sudo dpkg --configure -a sudo aptitude -f install wine sudo apt-get -f install wine 

但他们都没有解决它。

我还能尝试什么?

我使用Ubuntu 16.04 LTS(64位)并遇到同样的错误,“E:无法纠正问题,你已经破坏了包裹。” 在尝试安装mysql-workbench时。

我通过执行以下操作解决了问题:

  1. sudo apt autoremove(删除不再需要的包)
  2. sudo apt-get update
  3. sudo apt-get install package-name(例如wine,mysql-workbench等)

希望对你有效。

确保已启用Universe存储库。 Ubuntu软件 – >可从互联网下载检查前四并关闭。

在终端中键入以下命令:

$ sudo apt-get purge python3-software-properties

然后尝试安装

$ apt-get -f install(有时-f不起作用)