Dennis Lee

A real world example of editing Arch Linux AUR PKGBUILDs


I recently installed Interlink from the AUR. I’ll be writing about the choice of email client in a future post, but this post is about how I dealt with the broken AUR package for Interlink and how you can deal with broken AUR packages in general.

The Problem

First I tried just a simple yay -S interlink-bin, but that gave me this:

curl: (22) The requested URL returned error: 404 Not Found
==> ERROR: Failure while downloading

Ok, so it tried to download a file that doesn’t exist. It gives us the path to the file, so I went to the file’s parent folder to see if I could figure out what the problem was. It appears that the developer has released version 52.9.7463, and removed 52.9.7433, the one we were looking for! I flagged the package as “Out of Date” on the AUR page.

The Solution

I use yay as an AUR helper. It has an option called --editmenu, which gives you the option to edit the PKGBUILD before installing. Let’s try it:

yay -S interlink-bin --editmenu


OK, so we just have to fix the pkgver and it’ll grab the right file!

==> Validating source_x86_64 files with sha256sums...
    interlink-52.9.7463.linux-x86_64-gtk3.tar.xz ... FAILED
==> ERROR: One or more files did not pass the validity check!

Oh. OK, how about we just delete the sha256sums and sha256sums_x86_64 checksums from the file. That way, it can’t fail because there’s nothing to check, right?

==> ERROR: Integrity checks are missing for: source_x86_64 source

Oh. So, is there a way to tell it to skip integrity checks on the downloaded file? Turns out, there is.1


And with that, the package installs!

  1. Creating Packages For The Arch User Repository (AUR) - DistroTube - Invidious ↩︎