The instructions below describe the step-by-step guide on installing omnet++ in fedora 10:

The following packages need to be install before the omnet++ installation:
1. TCL/TK
2. BLT

Step 1: Installing TCL/TK
From the terminal extract tcl package in home directory:
# tar -xzf tcl8.4.18-src.tar.gz
Proceed by entering to the unix directory:
# cd tcl8.4.18/unix
# ./configure
# make
# make test
# make install

As above, from the terminal extract tk package in the same directory:
# tar -xzf tk8.4.18-src.tar.gz
Proceed by entering to the unix directory:
# cd tk8.4.18/unix
# ./configure–with-tcl=/usr/local/lib
# make
# make install

Remark: if error occur regarding during the installation please refer to the post "NS-2 in Fedora 10" and follow the solution at Step 5.

Step 2: Installing BLT
Extract the BLT package:
# tar -xzf BLT2.4z.tar.gz
Enter into the blt directory:
# cd blt2.4z
# ./configure --with-tcl=/usr/local/lib
# make
Enter into the demos directory and test the demo, a graphical window appear with 2 large fishes:
# cd demos
#./graph1.tcl
Entering back to blt directory and finish with the installation:
# cd ..
# make install

Step 3: Installing Omnet++
Download Omnet++ from http://www.omnetpp.org/filemgmt/index.php

Again, extract the Omnet++ to the home directory:
# tar zxvf omnetpp-3.3p1-src.gz

Before the installation took place we need to set the appropriate path at ./bashrc
At the terminal edit .bashrc:
# vi /root/.bashrc
Enter the following line to .bashrc:
------------------------------------------------------------------------------------
export PATH=$PATH:/home/omnetpp-3.3p1/bin
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/omnetpp-3.3p1/lib:/usr/local/lib
export TCL_LIBRARY=/usr/local/lib/tcl8.4
------------------------------------------------------------------------------------
Remark: Press "i" key to insert line to ./bashrc after finish editing press "Esc" key follow by ":" key and type "wq" to write and quit from vi.

Next, we need to edit the 'configure.user' file reside in omnetpp3.3p1 directory by comment out the line:
TK_CFLAGS=" -I/usr/local/include"
TK_LIBS=" -L/usr/local/lib -ltcl8.4 -ltk8.4"

Now we can proceed with the installation:
# ./configure
Make sure you see this before proceed to make:
Your PATH contains /home/omnetpp-3.3p1/bin. Good!
Your LD_LIBRARY_PATH is set. Good!
TCL_LIBRARY is set. Good!

# make
After make, test the samples at omnetpp/samples/dyna:
# cd dyna
# ./dyna

A network consist of server,switch and computer will appear.

*success* ^_^

Reference from the instruction above: http://blog.163.com/mchen_6431/blog/static/3228631220086210366137/#

Advertisements