1 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
2 # Local configure fragment for sysdeps/hppa/elf.
4 if test "$usetls" != no; then
5 # Check for support of thread-local storage handling in assembler and
7 AC_CACHE_CHECK(for hppa TLS support, libc_cv_hppa_tls, [dnl
8 cat > conftest.s <<\EOF
10 .section ".tdata","awT",@progbits
13 ; Test general dyanmic relocations
15 addil LT'foo-$tls_gdidx$, %r19
16 ldo RT'foo-$tls_gdidx$(%r1), %r26
19 ; Test local dynamic relocations
21 addil LT'foo-$tls_ldidx$, %r19
23 ldo RT'foo-$tls_ldidx$(%r1), %r26
24 ldo RR'foo-$tls_dtpoff$(%r1), %r25
25 ; More variables can be loaded...
26 ; Test initial exec reloctiosn
29 addil LT'foo-$tls_ieoff$, %r19
30 ldw RT'foo-$tls_ieoff$(%r1), %r25
32 ; Test local exec relocations
35 addil LR'foo-$tls_leoff$, %r26
36 ldo RR'foo-$tls_leoff$(%r1), %r25
37 ; Done all the TLS tests.
40 if AC_TRY_COMMAND(${CC-cc} -c $CFLAGS conftest.s 1>&AS_MESSAGE_LOG_FD); then
46 if test $libc_cv_hppa_tls = yes; then
47 AC_DEFINE(HAVE_TLS_SUPPORT)