![libglib2.0-0:amd64 安装/删除破坏了整个 ubuntu](https://linux22.com/image/944657/libglib2.0-0%3Aam%E2%80%8B%E2%80%8Bd64%20%E5%AE%89%E8%A3%85%2F%E5%88%A0%E9%99%A4%E7%A0%B4%E5%9D%8F%E4%BA%86%E6%95%B4%E4%B8%AA%20ubuntu%20.png)
我有 Ubuntu bullseye 11。我尝试安装需要 libglib 版本的 pspp。然后我尝试手动将 libglib 更新到较新的版本。然后我的系统出现以下问题。
libglib2.0-0:amd64 安装/删除破坏了整个 ubuntu
elias@eliasc:~/Downloads/_LINUX_PKGS$ sudo dpkg --configure -a
dpkg: error processing package libglib2.0-0:i386 (--configure):
package libglib2.0-0:i386 2.68.1-1~ubuntu21.04.1 cannot be configured because libglib2.0-0:amd64 is at a different version (2.68.4-1ubuntu1)
Setting up man-db (2.9.4-2) ...
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
Updating database of manual pages ...
man-db.service is a disabled or a static unit not running, not starting it.
Errors were encountered while processing:
libglib2.0-0:i386
elias@eliasc:~/Downloads/_LINUX_PKGS$ sudo apt-get install -f
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Correcting dependencies... failed.
The following packages have unmet dependencies:
appmenu-gtk-module-common : Depends: libglib2.0-bin
gdm3 : Depends: libglib2.0-bin (>= 2.35.0)
gnome-characters : Depends: libglib2.0-bin (>= 2.40.0-3)
gnome-shell : Depends: libglib2.0-bin (>= 2.53.0)
libfm-qt8 : Depends: libglib2.0-bin
libglib2.0-0 : Depends: libc6 (>= 2.34) but 2.33-0ubuntu5 is installed
Depends: libffi8 (>= 3.4) but it is not installable
Breaks: libglib2.0-0:i386 (!= 2.68.4-1ubuntu1) but 2.68.1-1~ubuntu21.04.1 is installed
libglib2.0-0:i386 : Breaks: libglib2.0-0 (!= 2.68.1-1~ubuntu21.04.1) but 2.68.4-1ubuntu1 is installed
libglib2.0-dev : Depends: libglib2.0-0 (= 2.68.1-1~ubuntu21.04.1) but 2.68.4-1ubuntu1 is installed
Depends: libglib2.0-bin (= 2.68.1-1~ubuntu21.04.1)
libglib2.0-dev-bin : Depends: libglib2.0-0 (= 2.68.1-1~ubuntu21.04.1) but 2.68.4-1ubuntu1 is installed
libglib2.0-tests : Depends: libglib2.0-0 (= 2.68.1-1~ubuntu21.04.1) but 2.68.4-1ubuntu1 is installed
libqt5xdg3 : Depends: libglib2.0-bin
lightdm : Depends: libglib2.0-bin
packagekit : Depends: libglib2.0-bin
tracker : Depends: libglib2.0-bin
ubuntu-settings : Depends: libglib2.0-bin (>= 2.53.4-3ubuntu1~)
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
E: Unable to correct dependencies
elias@eliasc:~/Downloads/_LINUX_PKGS$ sudo dpkg --force-all --configure -a
dpkg: error processing package libglib2.0-0:i386 (--configure):
package libglib2.0-0:i386 2.68.1-1~ubuntu21.04.1 cannot be configured because libglib2.0-0:amd64 is at a different version (2.68.4-1ubuntu1)
Errors were encountered while processing:
libglib2.0-0:i386
elias@eliasc:~/Downloads/_LINUX_PKGS$ sudo apt-get install -f libglib2.0-0=2.68.1-1~ubuntu21.04.1
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:
appmenu-gtk-module-common : Depends: libglib2.0-bin
gdm3 : Depends: libglib2.0-bin (>= 2.35.0)
gnome-characters : Depends: libglib2.0-bin (>= 2.40.0-3)
gnome-shell : Depends: libglib2.0-bin (>= 2.53.0)
libfm-qt8 : Depends: libglib2.0-bin
libglib2.0-dev : Depends: libglib2.0-bin (= 2.68.1-1~ubuntu21.04.1)
libqt5xdg3 : Depends: libglib2.0-bin
lightdm : Depends: libglib2.0-bin
packagekit : Depends: libglib2.0-bin
tracker : Depends: libglib2.0-bin
ubuntu-settings : Depends: libglib2.0-bin (>= 2.53.4-3ubuntu1~)
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
答案1
经典解决方案不起作用
输出说要降级但是 apt-get 无法解决降级过程:
sudo apt-get install -f libglib2.0-0=2.68.1-1~ubuntu21.04.1
然后我运行sudo aptitude
,在那里选择一些选项(单击相关库)以及一些不记得的点击。
瞧!它降级了许多库,包括 libglib2.0。
不再有损坏的系统!
请注意,以下命令建议卸载几乎整个系统!:
sudo dpkg --purge --force-depends libglib2.0-0