How To Install Elixir on macOS Catalina 10.15.7
Published on 22 November 2020 12:00 AM
- Git clone the ASDF repo
git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.8.0
- Add the following line to your ZSH config file
~/.zshrc
. $HOME/.asdf/asdf.sh
- Restart ZSH config
source ~/.zshrc
- Install ASDF plugins
asdf plugin add erlang
asdf plugin add elxir
- Install Elixir and Erlang manage versions
asdf install elixir latest
asdf install erlang latest
Possible errors
At the moment of writing this, I had macOS Catalina 10.15.7 and received the following error:
Unable to install on macOS: 'in6addr_any' follows non-static declaration
Here is how to fix it according to this Source
export CFLAGS="-O2 -g -fno-stack-check -Wno-error=implicit-function-declaration"
asdf install erlang 23.0.3