From 5556308cbfabb1eef63359dfec24b8bcff44cb94 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Mon, 12 Dec 2016 16:33:14 -0800 Subject: MySQL: Make sure we clean the libraries from mysql_config It prints libraries necessary for linking against the MySQL static library. When linking against dynamic libraries, we end up with too many parameters. We don't want to explicitly link our plugin to OpenSSL and this is especially important on macOS since Sierra no longer comes with OpenSSL development files. On my Linux: -L/usr/lib64 -lmysqlclient -lpthread -lz -lm -lssl -lcrypto -ldl On my macOS: -L/usr/local/Cellar/mysql/5.7.16/lib -lmysqlclient -lssl -lcrypto Instead, keep only -L options (that haven't been removed by the function $$filterLibraryPath above) and the actual client library. Change-Id: I3e3f0326f7234a26acf5fffd148fa985d0fd9c93 Reviewed-by: Oswald Buddenhagen --- src/sql/configure.json | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/sql/configure.json') diff --git a/src/sql/configure.json b/src/sql/configure.json index 96c82e84f9..72671b6df9 100644 --- a/src/sql/configure.json +++ b/src/sql/configure.json @@ -58,8 +58,10 @@ "label": "MySQL", "test": "unix/mysql", "sources": [ - { "type": "mysqlConfig", "query": "--libs_r" }, - { "type": "mysqlConfig", "query": "--libs" }, + { "type": "mysqlConfig", "query": "--libs_r", "cleanlibs": true }, + { "type": "mysqlConfig", "query": "--libs", "cleanlibs": true }, + { "type": "mysqlConfig", "query": "--libs_r", "cleanlibs": false }, + { "type": "mysqlConfig", "query": "--libs", "cleanlibs": false }, { "libs": "-lmysqlclient_r", "condition": "!config.win32" }, { "libs": "-llibmysql", "condition": "config.win32" }, { "libs": "-lmysqlclient", "condition": "!config.win32" } -- cgit v1.2.3