Skip to content

Instantly share code, notes, and snippets.

@ricardopadua
Last active February 20, 2025 15:21
Show Gist options
  • Save ricardopadua/1cff35f8c2a9fad7f6c815be44b47292 to your computer and use it in GitHub Desktop.
Save ricardopadua/1cff35f8c2a9fad7f6c815be44b47292 to your computer and use it in GitHub Desktop.
Installing Elixir and Erlang With ASDF ( Fedora )
#!/bin/bash
## Ricardo Pádua
## install asdf in fedora
## install curl and git
dnf install curl git
## install asdf
git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.9.0
## add the following to ~/.bashrc:
echo . '$HOME'/.asdf/asdf.sh >> ~/.bashrc
echo . '$HOME'/.asdf/completions/asdf.bash >> ~/.bashrc
## add the following to ~/.zshrc:
#echo . '$HOME'/.asdf/asdf.sh >> ~/.zshrc
#!/bin/bash
## Ricardo Pádua
## before asdf install
## CentOS & Fedora
##install the build tools
yum groupinstall -y 'Development Tools' 'C Development Tools and Libraries'
##automatic configure script builder
yum install -y autoconf
##needed for terminal handling
yum install -y ncurses-devel
##for building with wxWidgets (start observer or debugger!)
yum install -y wxGTK3-devel wxBase3
##for building ssl
yum install -y openssl-devel
##for jinterface
yum install -y java-1.8.0-openjdk-devel
##ODBC support
yum install -y libiodbc unixODBC-devel.x86_64 erlang-odbc.x86_64
##for the documentation to be built
yum install -y libxslt fop
## ASDF uses a plugin system to support multiple languages. For a typical Elixir
## project, you will need the Elixir and Erlang plugins:
asdf plugin add erlang
asdf plugin add elixir
## With ASDF and its plugins installed, you can now install Elixir and Erlang.
## If your project has a .tool-versions file with entries for elixir and erlang,
## you can install the correct versions by running the following from inside the project
asdf install
## to see a list of all available versions
asdf list-all erlang
## Unlike other version managers, ASDF requires you to specify a precise version
## of the language to install. To install version 23.3.4.10 of Erlang, run:
asdf install erlang 23.3.4.10
## to see a list of all available versions
asdf list-all elixir
## Notice that each Elixir release has multiple versions compiled with
## different major versions of Erlang/OTP. To maximize compatibility between
## Elixir and the Erlang runtime, choose a -otp-XY version that matches the
## major version of the runtime you installed in the previous step. For example:
asdf install elixir 1.11.2-otp-23
##to set a local version
asdf local erlang 23.2.1
asdf local elixir 1.11.2-otp-23
##to set a global, or default, version
#asdf global erlang 23.2.1
#asdf global elixir 1.11.2-otp-23
@ricardopadua
Copy link
Author

find /usr/lib64 -name "libwx_gtk3u_xrc*.so*"
find /usr -name wx-config
export KERL_CONFIGURE_OPTIONS="--enable-wx --with-wx-config=/usr/libexec/wxGTK/wx-config"
asdf uninstall erlang 27.1.3
asdf install erlang 27.1.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment