Package: tango-db
Version: 8.1.2c+dfsg-7
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu yakkety ubuntu-patch

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.

Thanks,

Robie Basak
Debian MySQL maintainers team
Ubuntu developer
Description: Use mysqlclient instead of mysqlclient_r
 The mysqlclient_r used to be the thread safe version of mysqlclient,
 but in both 5.5 and 5.6 mysqlclient was also thread safe and the two
 were equivalent, and in 5.7 mysqlclient_r was removed.
Author: Lars Tangvald <lars.tangv...@oracle.com>
Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/tango/+bug/1567266
Forwarded: no
Last-Update: 2016-04-07

--- a/configure
+++ b/configure
@@ -18669,14 +18669,14 @@
 $as_echo_n "checking for mysqlclient ... " >&6; }
     MYSQLCLIENT_LDFLAGS=""
     MYSQLCLIENT_CFLAGS=""
-    MYSQLCLIENT_LIBS="-lmysqlclient_r"
+    MYSQLCLIENT_LIBS="-lmysqlclient"
     mysqlclient_fail=""
 
         for tryprefix in /usr /usr/local /usr/mysql /usr/local/mysql /usr/pkg $mysqlclient_prefix ; do
 		for hloc in lib/mysql lib ; do
-			if test -f "$tryprefix/$hloc/libmysqlclient_r.so"; then
+			if test -f "$tryprefix/$hloc/libmysqlclient.so"; then
                 MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc"
-			elif test -f "$tryprefix/$hloc/libmysqlclient_r.a"; then
+			elif test -f "$tryprefix/$hloc/libmysqlclient.a"; then
                 MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc"
 			fi
 		done
@@ -18785,8 +18785,8 @@
 
 	if test "x$MYSQLCLIENT_CFLAGS" = "x"
 		then
-  		 	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No libmysqlclient_r libs found" >&5
-$as_echo "$as_me: WARNING: No libmysqlclient_r libs found" >&2;}
+  		 	{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No libmysqlclient libs found" >&5
+$as_echo "$as_me: WARNING: No libmysqlclient libs found" >&2;}
 			enable_dbserver=no
 		fi
 
--- a/configure.in
+++ b/configure.in
@@ -311,7 +311,7 @@
 	AM_PATH_MYSQLCLIENT
 	if test "x$MYSQLCLIENT_CFLAGS" = "x"
 		then
-  		 	AC_MSG_WARN(No libmysqlclient_r libs found)
+  		 	AC_MSG_WARN(No libmysqlclient libs found)
 			enable_dbserver=no
 		fi
 	
--- a/cppserver/database/DataBase.cpp
+++ b/cppserver/database/DataBase.cpp
@@ -297,19 +297,6 @@
 	WARN_STREAM << "DataBase::DataBase() create database device " << device_name << endl;
 
 //
-// Check if we are using the thread safe release of the MySQL library
-//
-
-	if (mysql_thread_safe() == 0)
-	{
-		ERROR_STREAM << "MySQL library used by this process is not tread safe. Please, use libmysqlclient_r" << endl;
-
-		Tango::Except::throw_exception((const char *)DB_MySQLLibNotThreadSafe,
-	   				  (const char *)"MySQL library used by this process is not thread safe. Please, use libmysqlclient_r or use DataBase release < 4.x",
-					  (const char *)"DataBase::DataBase()");
-	}
-
-//
 // Get user environment variables if defined
 //
 
--- a/m4/ac_path_mysqlclient.m4
+++ b/m4/ac_path_mysqlclient.m4
@@ -31,15 +31,15 @@
     AC_MSG_CHECKING([for mysqlclient ifelse([$1], , ,[>= v$1])])
     MYSQLCLIENT_LDFLAGS=""
     MYSQLCLIENT_CFLAGS=""
-    MYSQLCLIENT_LIBS="-lmysqlclient_r"
+    MYSQLCLIENT_LIBS="-lmysqlclient"
     mysqlclient_fail=""
 
     dnl test --with-mysqlclient-prefix
     for tryprefix in /usr /usr/local /usr/mysql /usr/local/mysql /usr/pkg $mysqlclient_prefix ; do
 		for hloc in lib/mysql lib ; do
-			if test -f "$tryprefix/$hloc/libmysqlclient_r.so"; then
+			if test -f "$tryprefix/$hloc/libmysqlclient.so"; then
                 MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc"
-			elif test -f "$tryprefix/$hloc/libmysqlclient_r.a"; then
+			elif test -f "$tryprefix/$hloc/libmysqlclient.a"; then
                 MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc"
 			fi
 		done
-- 
debian-science-maintainers mailing list
debian-science-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-science-maintainers

Reply via email to