Installing ns-2 @ *.mi.fu-berlin.de
===================================

Adaption of http://www.isi.edu/nsnam/ns/ns-build.html by Georg Wittenburg
(wittenbu@inf.fu-berlin.de), last updated on 18.5.2007.



We'll create a build environment and install ns-2 to $HOME/usr. Source code (as
linked from the URL above) and patch files  belong to $HOME/usr/src.



Basics
======

We're going to setup our build environment in $HOME/RAID/usr. For convenience
$HOME/RAID/usr is symlinked to $HOME/usr. We start by creating the necessary
directory structure.

	$ cd $HOME
	$ mkdir RAID/usr
	$ ln -s RAID/usr usr
	$ mkdir $HOME/usr/bin
	$ mkdir $HOME/usr/lib
	$ mkdir $HOME/usr/include
	$ mkdir $HOME/usr/man
	$ mkdir $HOME/usr/src

Now we need to adapt the shell environment variables to include these
directories. Specifically, "$HOME/usr/bin" needs to prepended to the PATH and
"$HOME/usr/lib" to the LD_LIBRARY_PATH. Depending on which shell you are
using, you either have to edit the file .cshrc or .bashrc both located in your
home directory.

Finally, download the latest packages for otcl, TclCL, ns-2, and nam from
http://www.isi.edu/nsnam/ns/ns-build.html and place them into the $HOME/usr/src
directory.



Tcl/Tk 8.4.14
=============

Tcl/Tk 8.4.9 is preinstalled and seems to work just fine.



otcl 1.13
=========

	$ tar -xvzf otcl-src-1.13.tar.gz
	$ cd otcl-1.13/
	$ ./configure --prefix=$HOME/usr
	$ make
	$ make install
	$ cd ..



TclCL 1.19
==========

	$ tar -xvzf tclcl-src-1.19.tar.gz
	$ cd tclcl-1.19/
	$ ./configure --prefix=$HOME/usr
	$ make
	$ make install
	$ cd ..



ns 2.31
=======

	$ tar -xvzf ns-src-2.31.tar.gz
	$ cd ns-2.31/
	$ ./configure --prefix=$HOME/usr
	$ make
	$ make install
	$ ./validate	# This is optional and takes a lot of time.
	$ cd ..



nam 1.13
========

	$ tar -xvzf nam-src-1.13.tar.gz
	$ cd nam-1.13/
	$ ./configure --prefix=$HOME/usr
	$ make
	$ make install
	$ ./validate	# This is optional and takes a lot of time.
	$ cd ..



The remaining packages are optional and not yet considered. Further, it is up
to you whether you want to save some disk space by removing the archive files
and the source code directories. Note however, that for serious work with ns-2
you should keep the code around for easy recompilation.