[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: OTCL installing problems
line gcc -0 otclsh -g ... should include "-lsocket" & "-lnsl" on solaris
platform. ( Do not add this if you are doing compilation on FreeBSD, and
may be other BSDs )
socket, connect, accept, bind etc. are part of "socket" library and
getpeername, gethostbyname etc. utility functions are part of "nsl"
library. So you need to add those 2 library names in your compilation
command.
Adding this 2 libraries will remove all the problems listed by you.
Thanks,
Miten.
> When running make for installing OTCL, in the way to use ns-2.0b17, I
> got the following error :
>
>
> $ make
> rm -f libotcl.so
> gcc -o otclsh -g -O -I. -I/home/users/livensw/pnni/tcl7.6/generic/
> -I/home/users/livensw/pnni/tk4.2/generic/ -I/usr/openwin/include
> otclAppInit.c \
> -L. -lotcl -L/home/users/livensw/lib/ -ltcl -ldl -lm
> Undefined first referenced
> symbol in file
> socket
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> getpeername
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> recv
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> gethostbyname
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> accept
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> send
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> bind
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> setsockopt
> /home/users/livensw/lib//libtcl.a(tclIOSock.o)
> getservbyname
> /home/users/livensw/lib//libtcl.a(tclIOSock.o)
> gethostbyaddr
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> getsockopt
> /home/users/livensw/lib//libtcl.a(tclIOSock.o)
> inet_addr
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> inet_ntoa
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> getsockname
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> listen
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> connect
> /home/users/livensw/lib//libtcl.a(tclUnixChan.o)
> ld: fatal: Symbol referencing errors. No output written to otclsh
> *** Error code 1
> make: Fatal error: Command failed for target `otclsh'
>
>
>
> I will really appriciate if someone coul dhelp me,
>
> Thanks,
>
> Alexander
> --
> ________________
> _________________________________________________\ /______
> \ /
> Alexandre Morin (DN9) Alcatel Telecom
> Phone: +32 3 240 7817 Research Division
> Fax: +32 3 240 9932 Francis Wellesplein 1
> mailto:[email protected] 2018 Antwerpen, Belgium
> ______________________________________________________\ /___________
> \ /
> \/
>
----------------------------------------------------------------------
Miten N. Mehta Graduate Research Assistant
3902, Collegemain, #908 Computer Science
Bryan, Texas A & M University
Texas-77801. College Station, TX-77843
Tel.#(409) 846 1451 (409) 845 5007
E-mail# [email protected]
Home Page : http://www.cs.tamu.edu/people/mmehta
----------------------------------------------------------------------
"UNTIL YOUR DREAMS COME TRUE, KEEP ON WORKING FOR THAT"
----------------------------------------------------------------------