The following examples show two main methods for installing Erlang/OTP on Ubuntu.
Simply run this command and it will download and install the latest stable Erlang release from Erlang Solutions.
$ sudo apt-get install erlang
Download the tar file:
$ wget http://erlang.org/download/otp_src_19.0.tar.gz
Extract the tar file:
$ tar -zxf otp_src_19.0.tar.gz
Enter the extracted directory and set ERL_TOP
to be the current path:
$ cd otp_src_19.0
$ export ERL_TOP=`pwd`
Now before configuring the build, you want to make sure you have all the dependencies you need in order to install Erlang:
Basic dependencies:
$ sudo apt-get install autoconf libncurses-dev build-essential
Other applications dependencies
Application | Dependency install |
---|---|
HiPE | $ sudo apt-get install m4 |
ODBC | $ sudo apt-get install unixodbc-dev |
OpenSSL | $ sudo apt-get install libssl-dev |
wxWidgets | $ sudo apt-get install libwxgtk3.0-dev libglu-dev |
Documentation | $ sudo apt-get install fop xsltproc |
Orber and other C++ projects | $ sudo apt-get install g++ |
jinterface | $ sudo apt-get install default-jdk |
Configure and build:
You can set your own options, or leave it blank to run the default configuration. Advanced configuration and build for Erlang/OTP.
$ ./configure [ options ]
$ make
Testing the build:
$ make release_tests
$ cd release/tests/test_server
$ $ERL_TOP/bin/erl -s ts install -s ts smoke_test batch -s init stop
After running these commands, open $ERL_TOP/release/tests/test_server/index.html
with your web browser and check that you don't have any fails. If all tests passed we're ok to continue to the installation.
Installing:
$ make install