Problem scenario
You want to install Erlang on a Linux SUSE machine. What should you do?
Solution
Run this script with sudo (e.g., sudo bash /tmp/erlang.sh):
# Written by www.continualintegration.com
#/bin/bash
widgetversion=3.0.4
echo "This script can take 20 minutes to complete"
zypper -n install ncurses gcc-c++ autoconf make git python3 bzip2 gtk2 gtk3 gtk2-devel ncurses-utils ncurses-devel
cd /tmp/
curl -Ls https://github.com/wxWidgets/wxWidgets/releases/download/v$widgetversion/wxWidgets-$widgetversion.tar.bz2 > /tmp/wxWidgets-$widgetversion.tar.bz2
cp /tmp/wxWidgets-$widgetversion.tar.bz2 /bin/
cd /bin/
bzip2 -d wxWidgets-$widgetversion.tar.bz2
tar -xf wxWidgets-$widgetversion.tar
#cd wxWidgets-$widgetversion
cd /bin/
git clone https://github.com/erlang/otp.git
cd otp
./otp_build autoconf
./configure
echo "This next portion may take 15 minutes"
date > /tmp/datetime.txt
make
make install
ln -s /usr/local/lib/erlang/bin/erl /usr/bin/erl
ln -s /usr/local/bin/erlc /usr/bin/erlc
ln -s /etc/alternatives/python3 /usr/bin/python
echo "Script run completed."
echo " "
echo "Many errors above (if there are any) may be ignorable"
echo "try the 'erl' command with no quotes to see if Erlang was installed"
echo 'If you get to a carrot prompt, use Ctrl-c, then type the "a" key and then press Enter.'