Subject: Re: correct use of '-lm' for mysql-client?
To: Andrew Gillham <>
From: Ignatios Souvatzis <>
List: tech-pkg
Date: 04/29/2000 15:59:24
On Sat, Apr 29, 2000 at 09:56:02AM -0400, Andrew Gillham wrote:
> Ignatios Souvatzis writes:
> > 
> > The programs using libmysqlclient need to link -lm, too, in this case.
> Is there a simple way of finding out what libraries are needed?  Not
> linking libm doesn't cause any kind of linker error.  Hypothetically I
> might need to link several different libraries against something, but there
> appears to be no way to know this. (except by runtime failures)
> Is this a weakness of shared libs, ELF, our ld.elf_so, or what?

It is a weakness of shared libs, as far as I can tell.

You find out what other libraries you need to link by reading the
documentation of the libraries you need directly. If the docs of 
-lmysql-client doesn't tell to link -lm, this hint should be added.

 * Progress (n.): The process through which Usenet has evolved from
   smart people in front of dumb terminals to dumb people in front of
   smart terminals.  -- (obscurity)