HI all,sorry for my poor English im a newbie in linux and im trying to implement LEACH on ns2.27. I must send a special thank to Knudfl, base on ur instructions, i do install successfully ns2.27 in ubuntu 10.04. Now on the LEACH phase,im stuck. I read the whole thead 18 page (which is closed) and have some questions. Please guide me.
1. I cant Make -f the knudfl's file (please see the below)
trung@ubuntu:~/ns-allinone-2.27/ns-2.27$ make -f 1-LEACH-Makefile-modified.txt.doc
1-LEACH-Makefile-modified.txt.doc:1: warning: NUL character seen; rest of line ignored
1-LEACH-Makefile-modified.txt.doc:1: *** missing separator. Stop.
2. So im trying the LEACH-makefile-org, ( already edit the gcc,g++ >>3.3;add DMIT_uAMPS; -I./mit/rca -I./mit/uAMPS and 3 lines after GAF...)
then, result in error
http://www.linuxquestions.org/questi...379/page2.html post#25
3. I try ur instruction in #26 ,which i dont understand clearly.
i do :
cd otcl-1.13/ && ./configure --prefix=/usr --enable-release --enable-devel
and Make >>> error below
trung@ubuntu:~/ns-allinone-2.27/otcl-1.13$ make
rm -f libotcl.so otcl.o so_locations
gcc -c -g -O2 -fsigned-char -fno-inline -DUSE_SHM -fpic -I. -I/home/trung/ns-allinone-2.27/tk8.4.18/generic -I/home/trung/ns-allinone-2.27/tcl8.4.18/generic -I/home/trung/ns-allinone-2.27/tcl8.4.18/generic -I/include otcl.c
ld -shared -o libotcl.so otcl.o
otcl.o: In function `OTclDispatch':
/home/trung/ns-allinone-2.27/otcl-1.13/otcl.c:495: undefined reference to `__stack_chk_fail_local'
otcl.o: In function `Otcl_Init':
/home/trung/ns-allinone-2.27/otcl-1.13/otcl.c:2284: undefined reference to `__stack_chk_fail_local'
ld: libotcl.so: hidden symbol `__stack_chk_fail_local' isn't defined
ld: final link failed: Nonrepresentable section on output
make: *** [libotcl.so] Error 1
Bypass it, i try the next step with tclcl-1.19, result in below:
trung@ubuntu:~/ns-allinone-2.27/tclcl-1.19$ make
make: Nothing to be done for `all'.
trung@ubuntu:~/ns-allinone-2.27/tclcl-1.19$ sudo make install
/usr/bin/install -c -m 644 *.h /usr/include
/usr/bin/install -c tcl2c++ /usr/bin
/usr/bin/install -c libtclcl.a /usr/lib
ranlib /usr/lib/libtclcl.a
...and the next 2 sudo apt command :
trung@ubuntu:~/ns-allinone-2.27/otcl-1.13$ sudo apt-get remove tcl8.5-dev tk8.5-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package tcl8.5-dev is not installed, so not removed
Package tk8.5-dev is not installed, so not removed
You might want to run `apt-get -f install' to correct these:
The following packages have unmet dependencies:
libstdc++5-3.3-dev: Depends: libstdc++5 (>= 1:3.3.6-15ubuntu4) but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
trung@ubuntu:~/ns-allinone-2.27/otcl-1.13$ sudo apt-get install tcl8.4-dev tk8.4-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
tcl8.4-dev is already the newest version.
tk8.4-dev is already the newest version.
You might want to run `apt-get -f install' to correct these:
The following packages have unmet dependencies:
libstdc++5-3.3-dev: Depends: libstdc++5 (>= 1:3.3.6-15ubuntu4) but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
Please help me this problem.. thank u!
Best regards!