aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/configure.ac')
-rw-r--r--xorg-server/configure.ac11
1 files changed, 8 insertions, 3 deletions
diff --git a/xorg-server/configure.ac b/xorg-server/configure.ac
index 120321e7c..9b3e2be2b 100644
--- a/xorg-server/configure.ac
+++ b/xorg-server/configure.ac
@@ -597,9 +597,14 @@ dnl GLX build options
AC_ARG_ENABLE(aiglx, AS_HELP_STRING([--enable-aiglx], [Build accelerated indirect GLX (default: enabled)]),
[AIGLX=$enableval],
[AIGLX=yes])
-AC_ARG_ENABLE(glx-tls, AS_HELP_STRING([--enable-glx-tls], [Build GLX with TLS support (default: disabled)]),
+AX_TLS
+AC_ARG_ENABLE(glx-tls, AS_HELP_STRING([--enable-glx-tls], [Build GLX with TLS support (default: auto)]),
[GLX_USE_TLS=$enableval],
- [GLX_USE_TLS=no])
+ [GLX_USE_TLS=no
+ if test "${ac_cv_tls}" != "none" ; then
+ GLX_USE_TLS=yes
+ fi])
+AC_SUBST(GLX_TLS, ${GLX_USE_TLS})
dnl Extensions.
AC_ARG_ENABLE(registry, AS_HELP_STRING([--disable-registry], [Build string registry module (default: enabled)]), [XREGISTRY=$enableval], [XREGISTRY=yes])
@@ -1008,7 +1013,7 @@ else
fi
AM_CONDITIONAL(AIGLX, test "x$AIGLX" = xyes)
-if test "x$GLX_USE_TLS" = xyes -a "x$AIGLX" = xyes; then
+if test "x$GLX_USE_TLS" = xyes ; then
GLX_DEFINES="-DGLX_USE_TLS -DPTHREADS"
GLX_SYS_LIBS="$GLX_SYS_LIBS -lpthread"
fi