Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help me! Error when running my C program with MYSQL

Status
Not open for further replies.

jdsun

Programmer
Feb 2, 2004
1
CN
I write a C program to save data into MYSQL database on Solaris 5.8.
my Makefile is :
CC=gcc
INCLUDES = -I/usr/local/mysql/include/mysql
LIBS = -L/usr/local/mysql/lib/mysql -lmysqlclient -lm -lsocket -lnsl -lz

all: kscsbt

KStringCounting.o: KStringCounting.c KString.h
$(CC) -c $(INCLUDES) KStringCounting.c

kscsbt: KStringCounting.o
$(CC) -o kscsbt KStringCounting.o $(LIBS)

-------------
but Error occur when runing kscsbt:
ld.so.1: kscsbt: fatal: libmysqlclient.so.12: open failed: No such file or directory
Killed

?????
Would you please tell me why?
Thank you very much.
 
search libmysqlclient.so in your library path. If it is not in library parth, you should add some more

Ion Filipski
1c.bmp
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top