For playing with distributed stuff, I’m using a bunch of Ubuntu ‘machines’ running under VMWare Server. There’s no particular reason for using Ubuntu other than that I happened to have a VM image (Ubuntu-6.06.1-desktop-i386) kicking around already, and it’s not really necessary to compile as packages are available, but I prefer it that way. Anyway, for reference, here is a quick guide to compiling Erlang from the starting point of a basic Ubuntu installation:
- From your home directory, get the Erlang source: wget http://www.erlang.org/download/otp_src_R11B-5.tar.gz
- Unpack it: tar -xzf otp_src_R11B-5.tar.gz
- Get a working gcc: sudo apt-get install build-essential
- Get the ncurses development libraries: sudo apt-get install libncurses5-dev
- Get m4: sudo apt-get install m4
- Optionally, get the ssl libraries: sudo apt-get install libssl-dev
- Go into the erlang source directory: cd otp_src_R11B-5
- Run the configuration script: ./configure
- Compile it all: make
- Install it: sudo make install
The above should all go smoothly, leaving you with a working Erlang setup. To confirm this, type erl to get an Erlang prompt.
文章转自:http://ciarang.com/posts/compiling-erlang-on-ubuntu