ubuntu 22.04 jammy oibaf 软件包损坏

ubuntu 22.04 jammy oibaf 软件包损坏

我为 oibaf 安装了 ppa,但在安装过程中发现软件包损坏。请帮我修复它...

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 libgl1-mesa-dri : Depends: libglapi-mesa (= 22.0.1-1ubuntu2) but 22.2~git2204280600.b4bbf9~oibaf~j is installed

现在我无法使用 ppa purge 恢复,因为它正在尝试删除大多数 OS 包,包括 gnome 应用程序。

以下是安装 oibaf 包时的 apt 历史记录:

Start-Date: 2022-04-29  01:18:24
Commandline: apt-get dist-upgrade
Requested-By: ahmety (1000)
Install: libllvm14:amd64 (1:14.0.0-1ubuntu1, automatic)
Upgrade: libcurl4:amd64 (7.81.0-1, 7.81.0-1ubuntu1.1), networkd-dispatcher:amd64 (2.1-2, 2.1-2ubuntu0.22.04.1), libcurl3-gnutls:amd64 (7.81.0-1, 7.81.0-1ubuntu1.1), libglx-mesa0:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libgbm1:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libcurl4-gnutls-dev:amd64 (7.81.0-1, 7.81.0-1ubuntu1.1), libdrm-nouveau2:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j), libxatracker2:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libvdpau1:amd64 (1.4-3build2, 1.5-1~oibaf~j), mesa-va-drivers:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libgl1-mesa-dri:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libdrm-common:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j), vdpau-driver-all:amd64 (1.4-3build2, 1.5-1~oibaf~j), mesa-vulkan-drivers:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), snapd:amd64 (2.55.3+22.04, 2.55.3+22.04ubuntu1), libglapi-mesa:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), libdrm-amdgpu1:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j), libdrm-radeon1:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j), libdrm2:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j), curl:amd64 (7.81.0-1, 7.81.0-1ubuntu1.1), libegl-mesa0:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), mesa-vdpau-drivers:amd64 (22.0.1-1ubuntu2, 22.2~git2204280600.b4bbf9~oibaf~j), microsoft-edge-stable:amd64 (100.0.1185.50-1, 101.0.1210.32-1), libdrm-intel1:amd64 (2.4.110-1ubuntu1, 2.4.110+git2204220500.d95b12~oibaf~j)
Error: Sub-process /usr/bin/dpkg returned an error code (1)
End-Date: 2022-04-29  01:18:48

实际上,我知道以下错误是问题的原因:

dpkg: error processing archive libgl1-mesa-dri_22.2~git2204280600.b4bbf9~oibaf~j_amd64.deb (--install):
 trying to overwrite '/usr/lib/x86_64-linux-gnu/dri/i915_dri.so', which is also in package libgl1-amber-dri:amd64 21.3.7-0ubuntu1
Errors were encountered while processing:
 libgl1-mesa-dri_22.2~git2204280600.b4bbf9~oibaf~j_amd64.deb

答案1

目前 PPA 中似乎存在依赖性问题。它不分发libgl1-amber-dri,但其中一个软件包推荐它,但有一个冲突的文件。无论如何,以下内容应该可以解决问题:

sudo dpkg --remove libgl1-amber-dri
sudo apt install --fix-broken --no-install-recommends

我们用 删除坏包dpkg(因为apt在依赖关系损坏的情况下很难做事)。然后,我们让它apt自行修复,但告诉它不要安装推荐的包。

相关内容