List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:July 23 1999 11:41am
Subject:Re: libmysqlclient problem
View as plain text  
At 4:13 AM -0500 7/23/99, Hotdog wrote:
>  I had installed mysql on Linux,FreeBSD,Sco osv and other system,all
>seems nice.
>Now,I installed mysql on Sun Solaras 7.0-intel-x86 box,but now, some
>problem take
>  On Solaras 7, Mysql can be success compiled and run. (But there is still
>a little
>problem,term.h,i had to modify it). But,when compile myself programs,error
>Compile system file...
>Undefined                       first referenced
> symbol                             in file
>socket                              /usr/local/lib/mysql/
>gethostbyname                       /usr/local/lib/mysql/
>setsockopt                          /usr/local/lib/mysql/
>getservbyname                       /usr/local/lib/mysql/
>getsockopt                          /usr/local/lib/mysql/
>inet_addr                           /usr/local/lib/mysql/
>shutdown                            /usr/local/lib/mysql/
>connect                             /usr/local/lib/mysql/
>ld: fatal: Symbol referencing errors. No output written to sys/checkpassword
>I using the following command to compile program:
>cc -w -I/usr/local/include/mysql -L/usr/local/lib/mysql checkpassword.c -o
>heckpassword -lm -lmysqlclient -lcrypt
>The include files sys/socket.h & netdb.h are all ok.
>Anyone can tell me how can I do now ?

Add -lsocket -lnsl to your command.

Paul DuBois, paul@stripped
libmysqlclient problemJani Tolonen23 Jul
Re: libmysqlclient problemPaul DuBois23 Jul