Installing Homebrew on Arch (Manjaro) Linux
TLDR: pacman -Syu libxcrypt-compat
Being a MacOS user refugee, I've long appreciated and used Homebrew as a user-mode package manager. While Linux distros are famous for their truly excellent package management utilities, I just like Homebrew. I know it, it's single-user capable which is what I prefer (no root necessary), and it works.
Except for one thing: installation fails on Manjaro Linux (an Arch derivative). It claims there's no Ruby available to it at the version it needs - not even the version that the installer fetches and embeds within brew
itself!
Well I thought that was just nuts. So I dug around the guts a little and ran Ruby 2.6.8 as shipped with Homebrew and found that it complains a cryptographic library is missing at runtime. So, simple solution: install the library!
$ sudo pacman -Syu libxcrypt-compat
And that's it, brew
should now install and run just fine on Arch.
Quick tip: to install Homebrew on Linux WITHOUT sudo/root, first make sure that you don't have a valid/active sudo session when you run the installer script. Then, it should give you an option to CTRL+D to not use root/sudo - so do that to install to $HOME/.linuxbrew/
. Set up your shell according to the directions and you should be good to go from there.