This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: MySQL server under cygwin

I have tried that, but no client applications can connect to the windows
version of the server, instead they die with
"ERROR 2002: Can't connect to local MySQL server through socket
'/tmp/mysql.sock' (2)"

I think i need to link them with the import library for the windows version
of the server, but then i get undefined references to loads of functions
defined in libmysqlclient.a but not in libmySQL.dll, such as the mysql
striing functions and many of the 'mysys' functions.

How have you resolved this?


----- Original Message -----
From: "Gerrit P. Haase" <>
To: "Terry Flannery" <>
Cc: <>
Sent: Sunday, July 28, 2002 10:34 AM
Subject: Re: MySQL server under cygwin

> Hallo Terry,
> Am Sonntag, 28. Juli 2002 um 03:47 schriebst du:
> > Yes it is. I would at least like to ba able to have cygwin enabled mysql
> > client applications... is this possible?
> Yes, libmysqlclient works fine when compiled under Cygwin.
> Once you have a static libmysqlclient.a it is possible to
> create a shared .dll from it.
> With the clientlib you can link most applications to enable
> the access to a MySQL server.
> Just add '--without-server' to the configure options.
> After you have a static lib you can create a shared lib
> like this (steamroller tactics):
> gcc -shared -o cygmysqlclient-3.23.51.dll \
>  -Wl,--out-implib=libmysqlclient.dll.a -Wl,--export-all-symbols \
>  -Wl,--enable-auto-import -Wl,--whole-archive libmysqlclient.a \
>  -Wl,--no-whole-archive -lcrypt -lz
> You also need to modify the file /usr/lib/mysql/
> to point to the dll then:
> # The name that we can dlopen(3).
> dlname='/bin/cygmysqlclient-3.23.51.dll'
> # Names of this library.
> library_names='libmysqlclient.dll.a'
> # The name of the static archive.
> old_library='libmysqlclient.a'
> Gerrit
> --
> =^..^=
> --
> Unsubscribe info:
> Bug reporting:
> Documentation:
> FAQ:         

Unsubscribe info:
Bug reporting:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]