<div dir="ltr">Racket's thread cells are local to 'Racket Threads', so I doubt that they map to OS level thread local storage, and thus would work fine.</div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Mon, Feb 25, 2013 at 8:07 PM, Neil Toronto <span dir="ltr"><<a href="mailto:neil.toronto@gmail.com" target="_blank">neil.toronto@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On 02/25/2013 06:17 PM, Matthew Flatt wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
At Tue, 26 Feb 2013 01:30:18 +0100, Juan Francisco Cantero Hurtado wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi. I have this issue when I compile racket with GCC 4.2 on OpenBSD:<br>
<br>
cd ../foreign; make all<br>
make foreign.lo<br>
/usr/bin/libtool --mode=compile --tag=CC cc -O2 -pipe -g<br>
-I/usr/local/include -I/usr/X11R6/include -DMZ_USE_JIT_SSE<br>
-I/usr/local/include -pthread -DMZ_USES_SHARED_LIB -I./../racket<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/include<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/src<br>
-c /usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/<u></u>foreign.c -o<br>
foreign.lo<br>
cc -O2 -pipe -g -I/usr/local/include -I/usr/X11R6/include<br>
-DMZ_USE_JIT_SSE -I/usr/local/include -pthread -DMZ_USES_SHARED_LIB<br>
-I./../racket<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/include<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/src<br>
-c /usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/<u></u>foreign.c -fPIC<br>
-DPIC -o .libs/foreign.o<br>
In file included from<br>
/usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/../<u></u>racket/include/scheme.<br>
h:1169,<br>
from<br>
/usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/../<u></u>racket/src/schpriv.h:2<br>
2,<br>
from<br>
/usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/<u></u>foreign.c:10:<br>
/usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/../<u></u>racket/include/schthre<br>
ad.h:483:<br>
error: thread-local storage not supported for this target<br>
Error while executing cc -O2 -pipe -g -I/usr/local/include<br>
-I/usr/X11R6/include -DMZ_USE_JIT_SSE -I/usr/local/include -pthread<br>
-DMZ_USES_SHARED_LIB -I./../racket<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/include<br>
-I/usr/ports/pobj/racket-5.3.<u></u>3/racket-5.3.3/src/foreign/../<u></u>racket/src<br>
-c /usr/ports/pobj/racket-5.3.3/<u></u>racket-5.3.3/src/foreign/<u></u>foreign.c -fPIC<br>
-DPIC -o .libs/foreign.o<br>
*** Error 2 in foreign (Makefile:43 'foreign.lo')<br>
*** Error 1 in foreign (Makefile:18 'all')<br>
*** Error 1 in racket (Makefile:130 'foreign-stuff')<br>
*** Error 1 in racket (Makefile:76 'common')<br>
*** Error 1 in racket (Makefile:79 'cgc')<br>
*** Error 1 in racket (Makefile:85 '3m')<br>
*** Error 1 in . (Makefile:40 '3m')<br>
*** Error 1 in /usr/ports/pobj/racket-5.3.3/<u></u>build-amd64 (Makefile:37 'all')<br>
<br>
<br>
I know the problem is the lack of support for TLS on OpenBSD/GCC. Now I<br>
compile racket with GCC 4.6 because this version has TLS support<br>
emulated but I think this workaround is adding other bugs to racket. Is<br>
it possible to compile racket in a OS/compiler without thread-local<br>
storage?.<br>
<br>
My configure options: --enable-libffi --enable-gracket --enable-jit<br>
--enable-foreign --enable-places --enable-float --enable-docs<br>
--enable-pthread --enable-lt=/usr/bin/libtool --enable-futures<br>
</blockquote>
<br>
Thread-local storage is needed for `--enable-places' and<br>
`--enable-futures', so you just have to leave those out to compile<br>
without it.<br>
</blockquote>
<br></div></div>
What do Racket's thread cells do when Racket is compiled without TLS?<span class="HOEnZb"><font color="#888888"><br>
<br>
Neil ⊥</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
____________________<br>
Racket Users list:<br>
<a href="http://lists.racket-lang.org/users" target="_blank">http://lists.racket-lang.org/<u></u>users</a><br>
</div></div></blockquote></div><br></div>