Issue with pacman: "error: failed to prepare transaction"
Trying to update my package database:
$ sudo pacman -Syu
[sudo] password for pietrom:
:: Synchronizing package databases...
core is up to date
extra 1770.5 KiB 259K/s 00:07 [######################################] 100%
community 5.3 MiB 150K/s 00:36 [######################################] 100%
multilib is up to date
:: Starting full system upgrade...
warning: fontconfig: local (2:2.13.91+23+g65087ac-1) is newer than extra (2:2.13.1+12+g5f5ec56-2)
warning: lib32-systemd: local (243.9-1) is newer than multilib (242.135-1)
warning: python-pip: local (19.2.3-1.4) is newer than extra (19.2.3-1)
warning: systemd: local (243.9-1) is newer than core (242.135-1)
warning: systemd-libs: local (243.9-1) is newer than core (242.135-1)
warning: systemd-sysvcompat: local (243.9-1) is newer than core (242.135-1)
resolving dependencies...
looking for conflicting packages...
error: failed to prepare transaction (could not satisfy dependencies)
:: installing pamac-common (9.0.0-3) breaks dependency 'pamac-common<9.0.0' required by pamac-qt
Apart from the warnings about the newer versions already installed, what is and how can I fix the last error?
What I am trying to update is my LLVM/clang version (from 8 to 9), which I failed to do with Pacman.
pacman
is telling you that it can’t update the system, because it can’t update a package without breaking a dependency.
You have a package installed called pamac-qt
. This package is listed as “experimental” and it is not compatible with the pamac 9 API. You’ll need to replace it with pamac-gtk
.
This should fix your issue:
pacman -S pamac-gtk
pacman -R pamac-qt
The best solution to resolve this issue is to remove all broken dependencies manually and then rerun sudo pacman -Syu
command. It works!
Remove the package and all its dependent packages:
sudo pacman -Runcs <package-name>
Then you can update the system and reinstall the package if needed.
-u, --unneeded remove unneeded packages
-n, --nosave remove configuration files
-c, --cascade remove packages and all packages that depend on them
-s, --recursive remove unnecessary dependencies