每次我尝试安装 virtualbox 5.1.22 应用程序时都会由于以下依赖关系而失败:
请帮忙。
The following packages have unmet dependencies:
virtualbox-5.1 : Depends: libpng16-16 (>= 1.6.2-1) but it is not installable
Depends: libqt5core5a (>= 5.6.0~beta) but 5.4.2+dfsg-2ubuntu9 is to be installed
Depends: libqt5printsupport5 (>= 5.0.2) but it is not going to be installed
Depends: libqt5widgets5 (>= 5.6.0~beta) but 5.4.2+dfsg-2ubuntu9 is to be installed
Depends: libqt5x11extras5 (>= 5.6.0) but it is not going to be installed
Depends: libvpx3 (>= 1.5.0) but it is not installable
Recommends: libsdl-ttf2.0-0 but it is not going to be installed
Recommends: pdf-viewer
答案1
第一步,尝试使用这些命令为某些库添加 universe 和 multiverse 存储库:
sudo add-apt-repository universe
sudo add-apt-repository multiverse
sudo apt update
sudo apt upgrade
然后尝试此命令来删除预览库:
sudo dpkg -r libqt5core5a libqt5widgets5
然后尝试安装依赖库:
sudo apt install libpng16-16 libqt5core5a libqt5printsupport5 libqt5widgets5 libqt5x11extras5
sudo apt -f install
然后尝试安装 virtualbox:
sudo apt install virtualbox