[Serdev] "-lm" required by mysql module?

Tom tom at sdf.com
Tue May 25 02:03:28 UTC 2004


On Mon, 24 May 2004, Andrei Pelinescu-Onciul wrote:

> On May 23, 2004 at 16:43, Tom <tom at sdf.com> wrote:
> >
> >   I had a small problem running the stable version of SER and loading the
> > mysql module:
> >
> > May 23 00:54:59 light ser: ERROR: load_module: could not open module
> > </usr/local/ser_0.8.12/lib/ser/modules/mysql.so>:
> > /usr/local/ser_0.8.12/lib/ser/modules/mysql.so: Undefined symbol "floor"
> >
> > This is on FreeBSD 5.2.1.  I added "-lm" to the LIBS list in the mysql
> > Makefile, and rebuilt and the problem disappeared.
> >
> >   Is FreeBSD the only arch that requires the mysql module to be linked
> > with the math library?  Otherwise, surely someone else would have seen
> > this before?
>
> Well, it works for me on FreeBSD 5.1, with mysql-client-3.23.54.
>
> mysql-client 3.23 is already linked with libm:
>
> ldd /usr/local/lib/mysql/libmysqlclient.so.10
> /usr/local/lib/mysql/libmysqlclient.so.10:
>         libz.so.2 => /usr/lib/libz.so.2 (0x28165000)
>         libcrypt.so.2 => /usr/lib/libcrypt.so.2 (0x28173000)
>         libm.so.2 => /usr/lib/libm.so.2 (0x2818c000)
>
> mysql-client 4.x is not:
> [this is on my linux machine]
> ldd /usr/lib/libmysqlclient.so.12
>         libz.so.1 => /usr/lib/libz.so.1 (0x40054000)
>         libssl.so.0.9.7 => /usr/lib/i686/cmov/libssl.so.0.9.7 (0x40066000)
>         libcrypto.so.0.9.7 => /usr/lib/i686/cmov/libcrypto.so.0.9.7 (0x40097000)        libc.so.6 => /lib/tls/libc.so.6 (0x40194000)
>         libdl.so.2 => /lib/tls/libdl.so.2 (0x402cf000)
>         /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
>
> However it works for me with mysql-client-4.0 on linux. Also the mysql module
> does not use "floor".

  Well, apparently  libmysqlclient does.

> Now the question is if this is a FreeBSD specific issue, or it comes
> from newer mysql versions.
>
> Can you send me your libmysqlclient version and the output of ldd on it?

  I'm using:

mysql-standard-4.0.12-unknown-freebsd4.7-i386

which is a binary build directly from www.mysql.com.  It does not have a
.so library.

  It seems that mysql.com now recommends people use the FreeBSD port
rather than their binaries, however, I dislike the port since I can only
have one mysql version installed at a time (or I have no found how to set
a version specific prefix).

> Thanks,
> Andrei


Tom




More information about the Serdev mailing list