libgl1-mesa 依赖和 apt 让我很困惑

libgl1-mesa 依赖和 apt 让我很困惑

我正在遵循说明这里为运行 Ubuntu 22.04 的 Dell XPS 13 下载 Lutris。

我一直在浏览论坛。我不知道自己在做什么。这似乎很简单,但我陷入了困境。我该如何摆脱依赖地狱?

matthias@matthias-XPS-13-9365:~$ sudo dpkg --configure --pending
matthias@matthias-XPS-13-9365:~$ sudo apt install libgl1-mesa-dri:i386 mesa-vulkan-drivers mesa-vulkan-drivers:i386
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
mesa-vulkan-drivers is already the newest version (22.3.1~kisak1~j).
mesa-vulkan-drivers set to manually installed.
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.5-0ubuntu0.1) but 22.3.1~kisak1~j is to be installed
                   Breaks: libgl1-mesa-dri:i386 (!= 22.0.5-0ubuntu0.1) but 22.3.1~kisak1~j is to be installed
 libgl1-mesa-dri:i386 : Depends: libdrm-amdgpu1:i386 (>= 2.4.110) but it is not going to be installed
                        Depends: libdrm-intel1:i386 (>= 2.4.38) but it is not going to be installed
                        Depends: libdrm-nouveau2:i386 (>= 2.4.66) but it is not going to be installed
                        Depends: libdrm-radeon1:i386 (>= 2.4.31) but it is not going to be installed
                        Depends: libxcb-dri3-0:i386 (>= 1.13) but it is not going to be installed
                        Breaks: libgl1-mesa-dri (!= 22.3.1~kisak1~j) but 22.0.5-0ubuntu0.1 is to be installed
 mesa-vulkan-drivers:i386 : Depends: libvulkan1:i386 but it is not going to be installed
                            Depends: libdrm-amdgpu1:i386 (>= 2.4.110) but it is not going to be installed
                            Depends: libxcb-dri3-0:i386 (>= 1.13) but it is not going to be installed
                            Depends: libxcb-present0:i386 but it is not going to be installed
                            Depends: libxcb-randr0:i386 (>= 1.13) but it is not going to be installed
                            Depends: libxcb-sync1:i386 but it is not going to be installed
                            Depends: libxcb-xfixes0:i386 but it is not going to be installed
                            Depends: libxshmfence1:i386 but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
matthias@matthias-XPS-13-9365:~$ sudo apt --fix-broken install
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  libffi7 libgl1-amber-dri libllvm13 libllvm13:i386
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libgl1-mesa-dri
The following packages will be upgraded:
  libgl1-mesa-dri
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/7,725 kB of archives.
After this operation, 765 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 146466 files and directories currently installed.)
Preparing to unpack .../libgl1-mesa-dri_22.3.1~kisak1~j_amd64.deb ...
Unpacking libgl1-mesa-dri:amd64 (22.3.1~kisak1~j) over (22.0.5-0ubuntu0.1) ...
dpkg: error processing archive /var/cache/apt/archives/libgl1-mesa-dri_22.3.1~kisak1~j_amd64.deb (--unpack):
 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:
 /var/cache/apt/archives/libgl1-mesa-dri_22.3.1~kisak1~j_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

matthias@matthias-XPS-13-9365:~$ apt list -i | grep libgl1*

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

libgl1-amber-dri/jammy,now 21.3.7-0ubuntu1 amd64 [installed,automatic]
libgl1-mesa-dri/jammy-updates,now 22.0.5-0ubuntu0.1 amd64 [installed,upgradable to: 22.3.1~kisak1~j]
libgl1/jammy,now 1.4.0-1 amd64 [installed,automatic]
libglapi-mesa/jammy,now 22.3.1~kisak1~j amd64 [installed,automatic]
libglapi-mesa/jammy,now 22.3.1~kisak1~j i386 [installed,automatic]
libgles2/jammy,now 1.4.0-1 amd64 [installed,automatic]
libglib-object-introspection-perl/jammy,now 0.049-1+build2 amd64 [installed,automatic]
libglib-perl/jammy,now 3:1.329.3-2build1 amd64 [installed,automatic]
libglib2.0-0/jammy-updates,now 2.72.4-0ubuntu1 amd64 [installed,automatic]
libglib2.0-0/jammy-updates,now 2.72.4-0ubuntu1 i386 [installed,automatic]
libglib2.0-bin/jammy-updates,now 2.72.4-0ubuntu1 amd64 [installed,automatic]
libglib2.0-data/jammy-updates,jammy-updates,now 2.72.4-0ubuntu1 all [installed,automatic]
libglibmm-2.4-1v5/jammy,now 2.66.2-2 amd64 [installed,automatic]
libglu1-mesa/jammy,now 9.0.2-1 amd64 [installed,automatic]
libglu1-mesa/jammy,now 9.0.2-1 i386 [installed,automatic]
libglvnd0/jammy,now 1.4.0-1 amd64 [installed,automatic]
libglvnd0/jammy,now 1.4.0-1 i386 [installed,automatic]
libglx-mesa0/jammy,now 22.3.1~kisak1~j amd64 [installed,automatic]
libglx0/jammy,now 1.4.0-1 amd64 [installed,automatic]

答案1

在运行了看起来相当可怕的程序后,我终于能够libgl-mesa-dri:i386安装 Vulkan 驱动程序sudo dpkg -P --force-depends libgl1-amber-dri:amd64。之后我重启了一下,并提醒自己要清除基萨克梅萨 PPA库并在升级我的操作系统之前删除 repo。

我仍然不知道自己在做什么。希望我能让 Zwift 正常工作,而不会损坏另一台计算机。

相关内容