Arch Linux - Manual Package Installation

I use a flavor of Arch Linux at work called Manjaro Linux.  I love it, but one thing that I always get tripped up on is the way that Arch and the pacman tool handle non-free software.  In almost all of the cases, I can usually find a package on the Arch Linux repo with what I need, but for some commercial apps, you have to install these yourself.  This is fine, and supported, but the process to do it is not clear to me, as opposed to how easy it is to work with yaourt to do package installs for everything else.

Let’s discuss how we can do that here.

Downloading the PKGBUILD manually

First, let’s download the PKGBUILD file manually. This can be done with the -G flag:

yaourt -G <pkgname>

Making packages

Next, download whatever sources you need to include and use. Any files that are downloaded and referenced locally relative to the PKGBUILD file, and run the makepkg command.

makepkg -i

This one command both builds and installs the package for you. Optionally, you can also specify the install step separately with

yaourt <pkgname.xz>

Finally, after the tool has made your packages, you can use yaourt to install them directly by just passing the .xz file in directly.

yaourt <pkgname.xz>