summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorDavi Arnaut <davi@mysql.com>2008-06-18 13:17:15 -0300
committerDavi Arnaut <davi@mysql.com>2008-06-18 13:17:15 -0300
commitfb8f32d0774876f79f7e3d9aa714c0ecb67adaca (patch)
treec6c8cd49b083e116e49ce10a1c7c3a63ac5eafa9 /configure.in
parent5d237db6f6719e7a1132bdb664ac2206c7bb8a9b (diff)
downloadmariadb-git-fb8f32d0774876f79f7e3d9aa714c0ecb67adaca.tar.gz
Bug#37003 Tests sporadically crashes with embedded server
The problem was that when a embedded linked version of mysqltest crashed there was no way to obtain a stack trace if no core file is available. Another problem is that the embedded version of libmysql was not behaving (crash) the same as the non-embedded with respect to sending commands to a explicitly closed connection. The solution is to generate a mysqltest's stack trace on crash and to enable "reconnect" if the connection handle was explicitly closed so the behavior matches the non-embedded one. client/CMakeLists.txt: Link mysys to mysqltest. client/Makefile.am: Link mysys to mysqltest. client/mysqltest.c: Add fatal signal handling with backtracing for Unix and Windows. configure.in: Add check for weak symbols support and remove a spurious word. include/Makefile.am: Add new header with prototype for stack tracing functions. include/my_stacktrace.h: Add new header with prototype for stack tracing functions. libmysqld/CMakeLists.txt: stack tracing is now part of mysys. libmysqld/Makefile.am: stack tracing is now part of mysys. libmysqld/lib_sql.cc: Re-connect if connection was explicitly closed. This is done to match the behavior of the non-embeded libmysql. mysql-test/t/sql_low_priority_updates_func.test: Test expects parallelism between queries that cannot be guaranteed under embedded. mysys/CMakeLists.txt: Add stacktrace to mysys. mysys/Makefile.am: Add stacktrace to mysys. mysys/stacktrace.c: Move stacktrace to mysys and add weak symbol for the C++ name de-mangling function so that it can later be overridden in C++ code. Also add my_ prefix to exported functions. sql/CMakeLists.txt: stacktrace was moved to mysys. sql/Makefile.am: stacktrace was moved to mysys. sql/mysqld.cc: Add my_ prefix to mysys functions.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in12
1 files changed, 11 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index af23b6035eb..033cabf1875 100644
--- a/configure.in
+++ b/configure.in
@@ -2341,10 +2341,20 @@ then
fi
AC_MSG_RESULT("$netinet_inc")
+AC_CACHE_CHECK([support for weak symbols], mysql_cv_weak_symbol,
+[AC_TRY_LINK([],[
+ extern void __attribute__((weak)) foo(void);
+], [mysql_cv_weak_symbol=yes], [mysql_cv_weak_symbol=no])])
+
+if test "x$mysql_cv_weak_symbol" = xyes; then
+ AC_DEFINE(HAVE_WEAK_SYMBOL, 1,
+ [Define to 1 if compiler supports weak symbol attribute.])
+fi
+
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_CHECK_HEADERS(cxxabi.h)
-AC_CACHE_CHECK([checking for abi::__cxa_demangle], mysql_cv_cxa_demangle,
+AC_CACHE_CHECK([for abi::__cxa_demangle], mysql_cv_cxa_demangle,
[AC_TRY_LINK([#include <cxxabi.h>], [
char *foo= 0; int bar= 0;
foo= abi::__cxa_demangle(foo, foo, 0, &bar);