summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure951
1 files changed, 943 insertions, 8 deletions
diff --git a/configure b/configure
index 73bd309c9..9341c504a 100755
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
#! /bin/sh
-# From configure.ac 9bce92f63.
+# From configure.ac 6d5542195.
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69.
#
@@ -633,6 +633,16 @@ MYSQL_VERSION
HAVE_MYSQL
MYSQL_CONFIG_HOME
DLLEXT
+USE_LIBBACKTRACE
+BACKTRACE_USES_MALLOC
+ALLOC_FILE
+VIEW_FILE
+BACKTRACE_SUPPORTS_DATA
+BACKTRACE_SUPPORTED
+LIBBACKTRACE_FORMAT_FILE
+BACKTRACE_SUPPORTS_THREADS
+BACKTRACE_FILE
+AWK
SOFLAGS
WITH_PLUGINS
AR
@@ -700,6 +710,7 @@ with_key1
with_key2
with_key3
enable_debug
+enable_libbacktrace
enable_buildbot
enable_rdtsc
enable_profiler
@@ -1355,6 +1366,9 @@ Optional Features:
--enable-epoll use epoll(4) on Linux
--enable-debug[=ARG] Compiles extra debug code. (yes by default)
(available options: yes, no, gdb)
+ --enable-libbacktrace[=ARG]
+ Compiles with libbacktrace. (no by default -
+ experimental)
--enable-buildbot[=ARG] (available options: yes, no)
--enable-rdtsc Uses rdtsc as timing source (disabled by default)
Enable it when you've timing issues. (For example:
@@ -1838,6 +1852,52 @@ $as_echo "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_func
+
+# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
+# ---------------------------------------------
+# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
+# accordingly.
+ac_fn_c_check_decl ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ as_decl_name=`echo $2|sed 's/ *(.*//'`
+ as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
+$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
+if eval \${$3+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$4
+int
+main ()
+{
+#ifndef $as_decl_name
+#ifdef __cplusplus
+ (void) $as_decl_use;
+#else
+ (void) $as_decl_name;
+#endif
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+ eval "$3=yes"
+else
+ eval "$3=no"
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+eval ac_res=\$$3
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+
+} # ac_fn_c_check_decl
cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
@@ -2195,7 +2255,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
ac_config_files="$ac_config_files Makefile src/common/Makefile"
-ac_config_files="$ac_config_files 3rdparty/mt19937ar/Makefile 3rdparty/libconfig/Makefile"
+ac_config_files="$ac_config_files 3rdparty/mt19937ar/Makefile 3rdparty/libconfig/Makefile 3rdparty/libbacktrace/Makefile 3rdparty/libbacktrace/backtrace-supported.h"
ac_config_files="$ac_config_files src/char/Makefile src/login/Makefile"
@@ -3457,8 +3517,13 @@ $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host OS" >&5
+$as_echo_n "checking host OS... " >&6; }
+host_os="`uname`"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $host_os" >&5
+$as_echo "$host_os" >&6; }
+
# Root-check
-host_is="`uname`"
case $host_os in
CYGWIN*)
;;
@@ -3739,6 +3804,34 @@ fi
#
+# libbacktrace
+#
+# Check whether --enable-libbacktrace was given.
+if test "${enable_libbacktrace+set}" = set; then :
+ enableval=$enable_libbacktrace;
+ enable_libbacktrace="$enableval"
+ case $enableval in
+ "no");;
+ "yes");;
+ *) as_fn_error $? "invalid argument --enable-libbacktrace=$enableval... stopping" "$LINENO" 5;;
+ esac
+
+else
+
+ case $host_os in
+ Linux* )
+ enable_libbacktrace="yes"
+ ;;
+ *)
+ enable_libbacktrace="no"
+ ;;
+ esac
+
+
+fi
+
+
+#
# Buildbot
#
# Check whether --enable-buildbot was given.
@@ -6222,6 +6315,390 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=address-use-after-scope" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=address-use-after-scope... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=address-use-after-scope"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=address-use-after-scope"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=address-use-after-scope" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=address-use-after-scope... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=pointer-overflow" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=pointer-overflow... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=pointer-overflow"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=pointer-overflow"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-overflow" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-overflow... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=builtin" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=builtin... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=builtin"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=builtin"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=builtin" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=builtin... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=pointer-compare" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=pointer-compare... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=pointer-compare"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=pointer-compare"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-compare" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-compare... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=pointer-subtract" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=pointer-subtract... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=pointer-subtract"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=pointer-subtract"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-subtract" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=pointer-subtract... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=shift-exponent" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=shift-exponent... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=shift-exponent"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=shift-exponent"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=shift-exponent" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=shift-exponent... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=shift-base" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=shift-base... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=shift-base"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=shift-base"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=shift-base" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=shift-base... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsanitize=sanitize-address-use-after-scope" >&5
+$as_echo_n "checking whether $CC supports -fsanitize=sanitize-address-use-after-scope... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsanitize=sanitize-address-use-after-scope"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsanitize=sanitize-address-use-after-scope"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=sanitize-address-use-after-scope" >&5
+$as_echo_n "checking whether $CC requires -fsanitize-undefined-trap-on-error for -fsanitize=sanitize-address-use-after-scope... " >&6; }
+ CFLAGS="$CFLAGS -fsanitize-undefined-trap-on-error"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
fi
fi
@@ -6230,6 +6707,33 @@ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fsigned-char" >&5
+$as_echo_n "checking whether $CC supports -fsigned-char... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -fsigned-char"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -fsigned-char"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wno-unused-parameter" >&5
$as_echo_n "checking whether $CC supports -Wno-unused-parameter... " >&6; }
@@ -8518,6 +9022,439 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
esac
#
+# libbacktrace
+#
+if test "$enable_libbacktrace" = "no" ; then
+ USE_LIBBACKTRACE="no"
+else
+ CPPFLAGS="$CPPFLAGS -DHAVE_LIBBACKTRACE"
+ USE_LIBBACKTRACE="yes"
+
+ # libbacktrace checks
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -funwind-tables" >&5
+$as_echo_n "checking whether $CC supports -funwind-tables... " >&6; }
+ OLD_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -funwind-tables"
+ OLD_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -funwind-tables"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int foo;
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+else
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ CFLAGS="$OLD_CFLAGS"
+ LDFLAGS="$OLD_LDFLAGS"
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+
+
+ for ac_prog in gawk mawk nawk awk
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_AWK+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test -n "$AWK"; then
+ ac_cv_prog_AWK="$AWK" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_AWK="$ac_prog"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+fi
+fi
+AWK=$ac_cv_prog_AWK
+if test -n "$AWK"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
+$as_echo "$AWK" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+ test -n "$AWK" && break
+done
+
+ case "$AWK" in
+ "")
+ as_fn_error $? "Libbacktrace requires awk to build" "$LINENO" 5
+ ;;
+ esac
+
+ backtrace_supported=yes
+ ac_fn_c_check_header_mongrel "$LINENO" "unwind.h" "ac_cv_header_unwind_h" "$ac_includes_default"
+if test "x$ac_cv_header_unwind_h" = xyes; then :
+ ac_fn_c_check_func "$LINENO" "_Unwind_Backtrace" "ac_cv_func__Unwind_Backtrace"
+if test "x$ac_cv_func__Unwind_Backtrace" = xyes; then :
+ BACKTRACE_FILE="backtrace.lo simple.lo"
+else
+
+ BACKTRACE_FILE="nounwind.lo"
+ backtrace_supported=no
+
+
+fi
+
+else
+
+ BACKTRACE_FILE="nounwind.lo"
+ backtrace_supported=no
+
+
+fi
+
+
+
+
+
+$as_echo "#define HAVE_GETIPINFO 1" >>confdefs.h
+
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking __sync extensions" >&5
+$as_echo_n "checking __sync extensions... " >&6; }
+if ${libbacktrace_cv_sys_sync+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+
+ if test -n "${with_target_subdir}"; then
+ case "${host}" in
+ hppa*-*-hpux*)
+ libbacktrace_cv_sys_sync=no
+ ;;
+ *)
+ libbacktrace_cv_sys_sync=yes
+ ;;
+ esac
+ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+ int i;
+int
+main ()
+{
+
+ __sync_bool_compare_and_swap(&i, i, i);
+ __sync_lock_test_and_set(&i, 1);
+ __sync_lock_release(&i);
+
+
+ ;
+ return 0;
+}
+
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ libbacktrace_cv_sys_sync=yes
+else
+ libbacktrace_cv_sys_sync=no
+
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ fi
+
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libbacktrace_cv_sys_sync" >&5
+$as_echo "$libbacktrace_cv_sys_sync" >&6; }
+ BACKTRACE_SUPPORTS_THREADS=0
+ if test "$libbacktrace_cv_sys_sync" = "yes"; then
+ BACKTRACE_SUPPORTS_THREADS=1
+
+$as_echo "#define HAVE_SYNC_FUNCTIONS 1" >>confdefs.h
+
+ fi
+
+
+ # Test for __atomic support.
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking __atomic extensions" >&5
+$as_echo_n "checking __atomic extensions... " >&6; }
+if ${libbacktrace_cv_sys_atomic+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+
+ if test -n "${with_target_subdir}"; then
+ libbacktrace_cv_sys_atomic=yes
+ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+ int i;
+int
+main ()
+{
+
+ __atomic_load_n(&i, __ATOMIC_ACQUIRE);
+ __atomic_store_n(&i, 1, __ATOMIC_RELEASE);
+
+
+ ;
+ return 0;
+}
+
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ libbacktrace_cv_sys_atomic=yes
+else
+ libbacktrace_cv_sys_atomic=no
+
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ fi
+
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libbacktrace_cv_sys_atomic" >&5
+$as_echo "$libbacktrace_cv_sys_atomic" >&6; }
+ if test "$libbacktrace_cv_sys_atomic" = "yes"; then
+
+$as_echo "#define HAVE_ATOMIC_FUNCTIONS 1" >>confdefs.h
+
+ fi
+
+ # The library needs to be able to read the executable itself. Compile
+ # a file to determine the executable format. The awk script
+ # filetype.awk prints out the file type.
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking output filetype" >&5
+$as_echo_n "checking output filetype... " >&6; }
+if ${libbacktrace_cv_sys_filetype+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+
+ filetype=
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int i;
+int
+main ()
+{
+int j;
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+ filetype=`${AWK} -f $srcdir/3rdparty/libbacktrace/filetype.awk conftest.$ac_objext`
+else
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "compiler failed
+See \`config.log' for more details" "$LINENO" 5; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ libbacktrace_cv_sys_filetype=$filetype
+
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libbacktrace_cv_sys_filetype" >&5
+$as_echo "$libbacktrace_cv_sys_filetype" >&6; }
+
+ # Match the file type to decide what files to compile.
+ LIBBACKTRACE_FORMAT_FILE=
+ backtrace_supports_data=yes
+ case "$libbacktrace_cv_sys_filetype" in
+ elf*)
+ LIBBACKTRACE_FORMAT_FILE="elf.o"
+ ;;
+ pecoff)
+ LIBBACKTRACE_FORMAT_FILE="pecoff.o"
+ backtrace_supports_data=no
+ ;;
+ xcoff*)
+ LIBBACKTRACE_FORMAT_FILE="xcoff.o"
+ backtrace_supports_data=no
+ ;;
+ macho*)
+ LIBBACKTRACE_FORMAT_FILE="macho.o"
+ backtrace_supports_data=no
+ ;;
+ *)
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not determine output file type" >&5
+$as_echo "$as_me: WARNING: could not determine output file type" >&2;}
+ LIBBACKTRACE_FORMAT_FILE="unknown.o"
+ backtrace_supported=no
+ ;;
+ esac
+
+
+ # ELF defines.
+ elfsize=
+ case "$libbacktrace_cv_sys_filetype" in
+ elf32)
+ elfsize=32
+ ;;
+ elf64)
+ elfsize=64
+ ;;
+ *)
+ elfsize=unused
+ esac
+
+cat >>confdefs.h <<_ACEOF
+#define BACKTRACE_ELF_SIZE $elfsize
+_ACEOF
+
+
+ # XCOFF defines.
+ xcoffsize=
+ case "$libbacktrace_cv_sys_filetype" in
+ xcoff32)
+ xcoffsize=32
+ ;;
+ xcoff64)
+ xcoffsize=64
+ ;;
+ *)
+ xcoffsize=unused
+ esac
+
+cat >>confdefs.h <<_ACEOF
+#define BACKTRACE_XCOFF_SIZE $xcoffsize
+_ACEOF
+
+
+ BACKTRACE_SUPPORTED=0
+ if test "$backtrace_supported" = "yes"; then
+ BACKTRACE_SUPPORTED=1
+ fi
+
+
+ BACKTRACE_SUPPORTS_DATA=0
+ if test "$backtrace_supports_data" = "yes"; then
+ BACKTRACE_SUPPORTS_DATA=1
+ fi
+
+
+ ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
+if test "x$ac_cv_func_mmap" = xyes; then :
+ have_mmap=yes
+else
+ have_mmap=no
+fi
+
+
+ VIEW_FILE=mmapio.lo
+ ALLOC_FILE=mmap.lo
+
+
+
+
+ BACKTRACE_USES_MALLOC=0
+ if test "$ALLOC_FILE" = "alloc.lo"; then
+ BACKTRACE_USES_MALLOC=1
+ fi
+
+
+ ac_fn_c_check_func "$LINENO" "dl_iterate_phdr" "ac_cv_func_dl_iterate_phdr"
+if test "x$ac_cv_func_dl_iterate_phdr" = xyes; then :
+ have_dl_iterate_phdr=yes
+else
+ have_dl_iterate_phdr=no
+fi
+
+ if test "$have_dl_iterate_phdr" = "yes"; then
+
+$as_echo "#define HAVE_DL_ITERATE_PHDR 1" >>confdefs.h
+
+ fi
+
+ # Check for the fcntl function.
+ if test -n "${with_target_subdir}"; then
+ case "${host}" in
+ *-*-mingw*)
+ have_fcntl=no
+ ;;
+ spu-*-*)
+ have_fcntl=no
+ ;;
+ *)
+ have_fcntl=yes
+ ;;
+ esac
+ else
+ ac_fn_c_check_func "$LINENO" "fcntl" "ac_cv_func_fcntl"
+if test "x$ac_cv_func_fcntl" = xyes; then :
+ have_fcntl=yes
+else
+ have_fcntl=no
+fi
+
+ fi
+ if test "$have_fcntl" = "yes"; then
+
+$as_echo "#define HAVE_FCNTL 1" >>confdefs.h
+
+ fi
+
+ ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
+if test "x$ac_cv_have_decl_strnlen" = xyes; then :
+ ac_have_decl=1
+else
+ ac_have_decl=0
+fi
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_DECL_STRNLEN $ac_have_decl
+_ACEOF
+
+ for ac_func in lstat readlink
+do :
+ as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
+ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
+ cat >>confdefs.h <<_ACEOF
+#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+done
+
+
+ ac_fn_c_check_func "$LINENO" "getexecname" "ac_cv_func_getexecname"
+if test "x$ac_cv_func_getexecname" = xyes; then :
+ have_getexecname=yes
+else
+ have_getexecname=no
+fi
+
+ if test "$have_getexecname" = "yes"; then
+
+$as_echo "#define HAVE_GETEXECNAME 1" >>confdefs.h
+
+ fi
+fi
+
+
+#
# Buildbot
#
case $enable_buildbot in
@@ -8598,11 +9535,6 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
#
# Host specific stuff
#
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host OS" >&5
-$as_echo_n "checking host OS... " >&6; }
-host_os="`uname`"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $host_os" >&5
-$as_echo "$host_os" >&6; }
fd_setsize=""
DLLEXT=".so"
case $host_os in
@@ -10418,6 +11350,7 @@ gives unlimited permission to copy, distribute and modify it."
ac_pwd='$ac_pwd'
srcdir='$srcdir'
+AWK='$AWK'
test -n "\$AWK" || AWK=awk
_ACEOF
@@ -10522,6 +11455,8 @@ do
"src/common/Makefile") CONFIG_FILES="$CONFIG_FILES src/common/Makefile" ;;
"3rdparty/mt19937ar/Makefile") CONFIG_FILES="$CONFIG_FILES 3rdparty/mt19937ar/Makefile" ;;
"3rdparty/libconfig/Makefile") CONFIG_FILES="$CONFIG_FILES 3rdparty/libconfig/Makefile" ;;
+ "3rdparty/libbacktrace/Makefile") CONFIG_FILES="$CONFIG_FILES 3rdparty/libbacktrace/Makefile" ;;
+ "3rdparty/libbacktrace/backtrace-supported.h") CONFIG_FILES="$CONFIG_FILES 3rdparty/libbacktrace/backtrace-supported.h" ;;
"src/char/Makefile") CONFIG_FILES="$CONFIG_FILES src/char/Makefile" ;;
"src/login/Makefile") CONFIG_FILES="$CONFIG_FILES src/login/Makefile" ;;
"src/map/Makefile") CONFIG_FILES="$CONFIG_FILES src/map/Makefile" ;;