One of my favorite things about Arch Linux is the Arch User Repository (AUR).
It’s a community maintained collection of packages for just about every damn
thing you may want or need.
One of my least favorite things about Arch Linux is that the Arch package manager, pacman
doesn’t install packages directly from the AUR.
Because of this, you can either take a manual approach to installing packages
from the AUR, or you can install an additional command that will allow you to
easily install packages directly from the AUR.
My choice is yay
.
With yay
installed, you can install packages from the AUR just like you can from the main Arch repository. The command’s syntax is a drop-in for pacman
so you can use yay
to install packages from either the main repository or the
AUR.
For the most part, yay
is a rock, but at least once that I can remember, I’ve run into an issue with it.
Fast forward to the present, I recently ran a system upgrade, without any problems at all. Then a few days later, I went to run another upgrade, and I was greeting with the following from yay
:
% yay -Syu
yay: error while loading shared libraries: libalpm.so.12: cannot open shared object file: No such file or directory
ZshFortunately, all that was necessary to get things up and running again was
removing yay
and then installing the latest version manually. Incidentally, this was the same thing that resolved my previous yay
issue.
To get things up and running again, you will need to:
- Remove
yay
by runningpacman -R yay
- Make a new directory and change to it (makes for easier cleanup):
mkdir /tmp/yay && cd /tmp/yay
- Download the latest
PKGBUILD
foryay
by running:curl -OJ 'https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=yay'
- Build and install the package by running
makepkg -si
- Get rid of of the evidence:
rm -rf /tmp/yay
To double check that things are back in working order, simply run yay
to
check:
% yay --version
yay v10.2.3 - libalpm v13.0.0
Zsh