help-gsasl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Possible issue with static win32 gsasl


From: Simon Josefsson
Subject: Re: Possible issue with static win32 gsasl
Date: Tue, 05 Oct 2010 23:06:40 +0200
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.2 (gnu/linux)

Lothar May <address@hidden> writes:

> Using static linking of gsasl (removing the other files from the lib
> directory) I get errors:
>
> -- cut here --
> C:\Projects\pokerth_mingw64\gsasl\examples>gcc -I..\include -L..\lib client.c 
> -l
> gsasl -o client
> c:/projects/pokerth_mingw64/mingw/bin/../lib/gcc/x86_64-w64-mingw32/4.5.1/../../
> ../../x86_64-w64-mingw32/bin/ld.exe: Dwarf Error: Offset (7872) greater than 
> or
> equal to .debug_abbrev size (601).
> ..\lib/libgsasl.a(vasnprintf.o):vasnprintf.c:(.text+0x96): undefined 
> reference t
> o `___chkstk'
> collect2: ld returned 1 exit status
> -- cut here --

I wonder if static linking can work at all under Windows when you are
mixing compilers?  I was using MinGW-w64 based on GCC 4.5.1 to build the
x86 binaries, but it is not certain that it is completely compatible
with TDM-GCC.  The 'chkstk' stuff is not something from gsasl or gnulib,
and looks likes some compiler internal stuff.  Hm.   Indeed, searching
for 'chkstk' and MinGW suggests this is a common problem.  I didn't see
any obvious solution though.  Some ideas are in:

http://dev.mysql.com/doc/refman/5.1/en/windows-client-compiling.html

But the MSVS references are odd.  As far as I can tell, there are no
Microsoft compiler involved in what we are doing at all.  So maybe the
link isn't relevant to your problem.

> Using the DLL seems to work fine, output is:
> -- cut here --
> C:\Projects\pokerth_mingw64\gsasl\examples>client
> Output:
> AGphcwBzZWNyZXQ=
>
> If server accepted us, we're done.
> -- cut here --

Shared libraries seems to work better generally, so if it is an option
for you I'd recommend that way.

I would still be interested in understanding whether static libraries
can ever work though, because otherwise I might as well disable them.

/Simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]