mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
Bug #43397 mysql headers redefine pthread_mutex_init
unnecessarily
The problem is that libmysqlclient.so is built with THREAD
undefined, while a client compiling against the same header
files will see THREAD as defined and definitions in
my_pthread.h will be included, possibly resulting in undefined
symbols that cannot be resolved with libmysqlclient.so.
The suggested solution is to require that clients wanting to
link with libmysqlclient.so should be built with
MYSQL_CLIENT_NO_THREADS defined. This requires a documentation
change, and more details for this will be supplied if this
patch is approved.
The MYSQL_CLIENT_NO_THREADS define was renamed from
UNDEF_THREADS_HACK, to get a more suitable (less suspicious)
name for the define. (The UNDEF_THREADS_HACK is retained for
backwards compatibility, though.)
This patch is also in anticipation of WL#4958, which will
remove this problem altogether by dropping the building of
libmysqlclient.
This commit is contained in:
parent
ead1ce94e6
commit
ab2f3dd2a2
5 changed files with 8 additions and 8 deletions
|
|
@ -276,7 +276,7 @@
|
|||
#endif
|
||||
|
||||
/* The client defines this to avoid all thread code */
|
||||
#if defined(UNDEF_THREADS_HACK)
|
||||
#if defined(MYSQL_CLIENT_NO_THREADS) || defined(UNDEF_THREADS_HACK)
|
||||
#undef THREAD
|
||||
#undef HAVE_LINUXTHREADS
|
||||
#undef HAVE_NPTL
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue