Hi Jean-Sebastien,

On Wed, Aug 10, 2011 at 6:45 AM, Jean-Sebastien Delfino
<jsdelf...@apache.org> wrote:
>
> That's what I meant when I mentioned 'convert usages of __thread to
> Posix thread TLS calls' in my previous post [1].
>
> __thread works for me with GCC on Mac OS X (using the GCC build from
> the HPC project [2]), but causes a compile error with Clang/LLVM. It's
> listed as a limitation of Clang on Mac OS X in the Clang user manual
> (look for __thread on this page [3]).
>

Does "Works for me" mean it compiles for you just fine AND during
runtime you are getting the expected behavior or does it just mean the
code compiles just fine if using GCC?

I am asking cause I googled a bit last night and from what I found I
had the feeling thread local isn't really supported on OS X during
runtime.

> Are you getting a compile error with GCC too? or just with Clang?

I forced myself to not install GCC on OS X if possible and thus the
compile errors I am getting are those reported by Clang.

>
> For now you could just run configure without --enable-threads, then
> later try to convert the few references to __thread to Posix thread
> TLS calls (i.e. pthread_key_create, pthread_getspecific,
> pthread_setspecific, pthread_key_delete).
>

Yep I am not using --enable-threads or I set it explicitly to
--disable-threads to avoid the compile error for the time being. I
will try to look into your Posix thread TLS calls suggestion today (I
as well have to get APR V2 and back out the symlinks I set so far).

Many thanks and best wishes!

Cheers
Daniel

Reply via email to