tech-userlevel archive

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

Re: Issues with libpthreads

On Fri Mar 04 2011 at 09:59:30 +0100, Peter Bex wrote:
> Hi all,
> I've been having some issues linking libraries to pthreads on the amd64
> platform with 5.0 and 5.1.  (so far the macppc platform seems unaffected;
> haven't tried any others).
> I'm working on some bindings to libsvn_client with a dynamic language
> (lang/chicken), but when those bindings are loaded using dlopen, I get
> mostly random segfaults.  According to Aleksej Saushev this is a bug in
> our libpthreads; he said that when linking something against pthreads
> it is required to link everything else in the program to libpthreads too.
> But that's impossible in this case; There are many other libraries that
> I would like to use from Chicken, and many are third-party so I can't
> just start linking them to libpthreads.
> Is mixing and matching pthreads-using libraries with non-pthreads-using
> libraries really impossible?

You need to load libpthread at startup or not at all.  You don't need
to link all libraries to libpthread, though.  For example, if you link
libsvn_client with your application, you could link libpthread to either
that or the application itself to have it load at startup.

älä karot toivorikkauttas, kyl rätei ja lumpui piisaa

Home | Main Index | Thread Index | Old Index