Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2002-09

mySQL

5 messages · 5 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

James Mills

I'm trying to use mySQL as the database system for my program, however...

Linking testdb
/usr/bin/ld: cannot find -lmysqlclient
testdb.pp(84) Warning: Error while linking

I have installed fpc using the .deb packages of Debian, but I've installed mysql from the sources...

Could someone help here please? thanks. I'd like to know how exactly to fix this problem, without trying to muck up my system.

thanks
James

Reply by email

Marco van de Voort
to James Mills
Show quoted text 12 lines
I'm trying to use mySQL as the database system for my program, however... Linking testdb /usr/bin/ld: cannot find -lmysqlclient testdb.pp(84) Warning: Error while linking I have installed fpc using the .deb packages of Debian, but I've installed mysql from the sources... Could someone help here please? thanks. I'd like to know how exactly to fix this problem, without trying to muck up my system.

Check if a libmysqlclient .so or .a exists somewhere on the system.

Then recompile, and pas -Fl<thatdir> to the compiler.

(better to add that -Fl<thatdir> to your fpc.cfg or ppc386.cfg file for the future)

Reply by email

Unknown author
to James Mills: I'm trying to use mySQL as the database system for my program, however... Linking testdb…
James Mills wrote 12 lines
I'm trying to use mySQL as the database system for my program, however... Linking testdb /usr/bin/ld: cannot find -lmysqlclient testdb.pp(84) Warning: Error while linking I have installed fpc using the .deb packages of Debian, but I've installed mysql from the sources... Could someone help here please? thanks. I'd like to know how exactly to fix this problem, without trying to muck up my system.

Make sure you have the mysql-devel packages installed. You need to have a libmysqlclient.so somewhere on your system. Normally, the devel package installs this.

Michael.

Reply by email

Fernando Lozano

Hi there,

Show quoted text 6 lines
> I'm trying to use mySQL as the database system for my program, > however... > > Linking testdb > /usr/bin/ld: cannot find -lmysqlclient > testdb.pp(84) Warning: Error while linking

For me (Red Hat 6.2) the command line woud be:

fpc testdb.pp -Fl/usr/lib/mysql -k-lz

[]s, Fernando Lozano

Reply by email

Hélio Cavichiolo Jr
to Fernando Lozano
Show quoted text 6 lines
> > I'm trying to use mySQL as the database system for my program, > however... > > > > Linking testdb > > /usr/bin/ld: cannot find -lmysqlclient > > testdb.pp(84) Warning: Error while linking

Or, place your mysql lib dir in the file /etc/ld.so.conf and apply de command ldconfig.

Helio Cavichiolo Jr Analista de Sistemas Esc Telecomunicações Ltda D e f i n i t y L i n u x

Reply by email