[debian-mysql] Bug#825083: Package links against libmysqlclient_r

Robie Basak robie.basak at ubuntu.com
Mon May 23 13:00:21 UTC 2016

Package: sysbench
Version: 0.4.12-1.1
Tags: patch
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu yakkety ubuntu-patch
Control: block -1 by 797260

Dear Maintainer,

Please stop linking against libmysqlclient_r and link directly against
libmysqlclient instead.

Your package currently links against libmysqlclient_r. libmysqlclient_r
was the thread-safe version of libmysqlclient in previous MySQL
releases. However, libmysqlclient has been itself been made thread-safe
since before the current libmysqlclient18. Thus libmysqlclient_r is
currently deprecated and provided as a compatibility symlink only, and
will disappear in MySQL 5.7. This change can be made now, in advance of
a possible future transition to libmysqlclient20, which does not provide
the _r variant.

In Ubuntu, we have done this with the attached quilt patch, which I
believe is also applicable to Debian. Please note that this requires
autoreconf so will only work if applied after my patch for bug 797260.


Robie Basak
Debian MySQL maintainers team
Ubuntu developer
-------------- next part --------------
Author: Robie Basak <robie.basak at canonical.com>
Description: use libmysqlclient instead of libmysqlclient_r
 The former supersedes the latter which no longer exists in MySQL 5.7.
Forwarded: no
Last-Update: 2016-04-14

--- a/acinclude.m4
+++ b/acinclude.m4
@@ -51,7 +51,7 @@
     ac_cv_mysql_libs=`echo ${ac_cv_mysql_libs} | sed -e 's/.libs$//' \
                       -e 's+.libs/$++'`
     AC_CACHE_CHECK([MySQL libraries], [ac_cv_mysql_libs], [ac_cv_mysql_libs=""])
-    MYSQL_LIBS="-L$ac_cv_mysql_libs -lmysqlclient_r"
+    MYSQL_LIBS="-L$ac_cv_mysql_libs -lmysqlclient"
 # If some path is missing, try to autodetermine with mysql_config
@@ -82,8 +82,7 @@
         if test [ -z "$ac_cv_mysql_libs" ]
             AC_MSG_CHECKING(MySQL linker flags)
-            MYSQL_LIBS=`${mysqlconfig} --libs | sed -e \
-            's/-lmysqlclient /-lmysqlclient_r /' -e 's/-lmysqlclient$/-lmysqlclient_r/'`
+            MYSQL_LIBS=`${mysqlconfig} --libs`

More information about the pkg-mysql-maint mailing list