ports/183001: [MAINTAINER] databases/mariadb55-{client, server}: Fix all mysql-dependent ports build
Alexandr Kovalenko
never at nevermind.kiev.ua
Tue Oct 15 19:00:01 UTC 2013
>Number: 183001
>Category: ports
>Synopsis: [MAINTAINER] databases/mariadb55-{client,server}: Fix all mysql-dependent ports build
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Tue Oct 15 19:00:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator: Alexandr Kovalenko
>Release: FreeBSD 9.2-STABLE amd64
>Organization:
Nevermind Ltd.
>Environment:
System: FreeBSD 9.2-STABLE amd64
>Description:
Build of all mysql-dependent ports (if mariadb55 was used as mysql port) was
broken on all OSVERSION < 1000052 systems by introduction of libexecinfo
library support.
This patch fixes the issue by adding ${LOCALBASE}/lib to output of respective
options of mysql_config (--libs, --libs_r, --libmysqld-libs).
>How-To-Repeat:
Install databases/mariadb55-client and try to build databases/php53-mysqli (for
example) without MYSQLND (thus - depenent on port's libmysqlclient).
>Fix:
Apply patch attached.
P.S. Not sure if patch file is really needed for -server port, but it won't
harm to add it.
diff --git a/databases/mariadb55-client/files/patch-scripts_mysql_config.sh b/databases/mariadb55-client/files/patch-scripts_mysql_config.sh
new file mode 100644
index 0000000..a17b750
--- /dev/null
+++ b/databases/mariadb55-client/files/patch-scripts_mysql_config.sh
@@ -0,0 +1,14 @@
+--- scripts/mysql_config.sh.orig 2013-09-20 01:34:23.000000000 +0300
++++ scripts/mysql_config.sh 2013-10-15 21:23:34.000000000 +0300
+@@ -108,8 +108,11 @@
+ # We intentionally add a space to the beginning and end of lib strings, simplifies replace later
+ libs=" $ldflags -L$pkglibdir -lmysqlclient @ZLIB_DEPS@ @NON_THREADED_LIBS@"
+ libs="$libs @openssl_libs@ @STATIC_NSS_FLAGS@ "
++libs="$libs -L%%LOCALBASE%%/lib "
+ libs_r=" $ldflags -L$pkglibdir -lmysqlclient_r @ZLIB_DEPS@ @CLIENT_LIBS@ @openssl_libs@ "
++libs_r="$libs_r -L%%LOCALBASE%%/lib "
+ embedded_libs=" $ldflags -L$pkglibdir -lmysqld @LIBDL@ @ZLIB_DEPS@ @LIBS@ @WRAPLIBS@ @openssl_libs@ "
++embedded_libs="$embedded_libs -L%%LOCALBASE%%/lib "
+
+ if [ -r "$pkglibdir/libmygcc.a" ]; then
+ # When linking against the static library with a different version of GCC
diff --git a/databases/mariadb55-server/Makefile b/databases/mariadb55-server/Makefile
index 85fe763..d240be8 100644
--- a/databases/mariadb55-server/Makefile
+++ b/databases/mariadb55-server/Makefile
@@ -2,7 +2,7 @@
PORTNAME?= mariadb
PORTVERSION= 5.5.33a
-PORTREVISION?= 0
+PORTREVISION?= 1
CATEGORIES= databases ipv6
MASTER_SITES= http://ftp.osuosl.org/pub/mariadb/${PORTNAME}-${PORTVERSION}/kvm-tarbake-jaunty-x86/ \
http://mirrors.supportex.net/mariadb/${PORTNAME}-${PORTVERSION}/kvm-tarbake-jaunty-x86/ \
@@ -133,6 +133,7 @@ EXTRA_PATCHES+= ${FILESDIR}/extra-patch-include_my_compare.h
post-patch:
@${REINPLACE_CMD} 's/*.1/${MAN1}/' ${WRKSRC}/man/CMakeLists.txt
+ @${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/scripts/mysql_config.sh
.include <bsd.port.pre.mk>
diff --git a/databases/mariadb55-server/files/patch-scripts_mysql_config.sh b/databases/mariadb55-server/files/patch-scripts_mysql_config.sh
new file mode 100644
index 0000000..a17b750
--- /dev/null
+++ b/databases/mariadb55-server/files/patch-scripts_mysql_config.sh
@@ -0,0 +1,14 @@
+--- scripts/mysql_config.sh.orig 2013-09-20 01:34:23.000000000 +0300
++++ scripts/mysql_config.sh 2013-10-15 21:23:34.000000000 +0300
+@@ -108,8 +108,11 @@
+ # We intentionally add a space to the beginning and end of lib strings, simplifies replace later
+ libs=" $ldflags -L$pkglibdir -lmysqlclient @ZLIB_DEPS@ @NON_THREADED_LIBS@"
+ libs="$libs @openssl_libs@ @STATIC_NSS_FLAGS@ "
++libs="$libs -L%%LOCALBASE%%/lib "
+ libs_r=" $ldflags -L$pkglibdir -lmysqlclient_r @ZLIB_DEPS@ @CLIENT_LIBS@ @openssl_libs@ "
++libs_r="$libs_r -L%%LOCALBASE%%/lib "
+ embedded_libs=" $ldflags -L$pkglibdir -lmysqld @LIBDL@ @ZLIB_DEPS@ @LIBS@ @WRAPLIBS@ @openssl_libs@ "
++embedded_libs="$embedded_libs -L%%LOCALBASE%%/lib "
+
+ if [ -r "$pkglibdir/libmygcc.a" ]; then
+ # When linking against the static library with a different version of GCC
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list