diff options
author | Petr Mladek <pmladek@suse.cz> | 2011-03-30 17:07:51 +0200 |
---|---|---|
committer | Petr Mladek <pmladek@suse.cz> | 2011-03-30 17:12:05 +0200 |
commit | ee55ce5ba0002a48fe3156d28ab1b5cfe934ff1c (patch) | |
tree | d87968f8631b726357dd0bcec7ebe18b34c63f42 | |
parent | drop bogus executable flag from idl/build/src and config files (diff) | |
download | core-ee55ce5ba0002a48fe3156d28ab1b5cfe934ff1c.tar.gz core-ee55ce5ba0002a48fe3156d28ab1b5cfe934ff1c.zip |
do not require mysql-devel package at runtime when using system mysql
useful for distro-specific builds
-rw-r--r-- | mysqlcppconn/makefile.mk | 11 | ||||
-rw-r--r-- | mysqlcppconn/mysql-connector-cpp-mysql-binding-dynamic.patch | 6 | ||||
-rw-r--r-- | mysqlcppconn/mysql-connector-cpp-mysql-binding-static.patch | 6 | ||||
-rw-r--r-- | mysqlcppconn/mysql-connector-cpp.patch | 6 |
4 files changed, 23 insertions, 6 deletions
diff --git a/mysqlcppconn/makefile.mk b/mysqlcppconn/makefile.mk index 60699c162499..e047ea06ffc4 100644 --- a/mysqlcppconn/makefile.mk +++ b/mysqlcppconn/makefile.mk @@ -49,8 +49,19 @@ ADDITIONAL_FILES=\ CONVERTFILES=\ cppconn$/build_config.h +# distro-specific builds want to link against a particular mysql library +# then they do not require mysql-devel package at runtime +# So put mysql-connector-cpp/driver/nativeapi/binding_config.h into separate patch +# and enable/disable MYSQLCLIENT_STATIC_BINDING according to the used mysql library +.IF "$(SYSTEM_MYSQL)" == "YES" +MYSQL_BINDING=static +.ELSE +MYSQL_BINDING=dynamic +.ENDIF + PATCH_FILES=\ $(TARFILE_NAME).patch \ + mysql-connector-cpp-mysql-binding-$(MYSQL_BINDING).patch \ patches/default_to_protocol_tcp.patch BUILD_DIR=driver diff --git a/mysqlcppconn/mysql-connector-cpp-mysql-binding-dynamic.patch b/mysqlcppconn/mysql-connector-cpp-mysql-binding-dynamic.patch new file mode 100644 index 000000000000..7007c3d16602 --- /dev/null +++ b/mysqlcppconn/mysql-connector-cpp-mysql-binding-dynamic.patch @@ -0,0 +1,6 @@ +--- misc/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:17:23.640625000 +0200 ++++ misc/build/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:13:50.359375000 +0200 +@@ -1 +1,2 @@ +-dummy ++#define HAVE_DLFCN_H 1 ++//#define MYSQLCLIENT_STATIC_BINDING 1 diff --git a/mysqlcppconn/mysql-connector-cpp-mysql-binding-static.patch b/mysqlcppconn/mysql-connector-cpp-mysql-binding-static.patch new file mode 100644 index 000000000000..b7edeb94d522 --- /dev/null +++ b/mysqlcppconn/mysql-connector-cpp-mysql-binding-static.patch @@ -0,0 +1,6 @@ +--- misc/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:17:23.640625000 +0200 ++++ misc/build/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:13:50.359375000 +0200 +@@ -1 +1,2 @@ +-dummy ++#define HAVE_DLFCN_H 1 ++#define MYSQLCLIENT_STATIC_BINDING 1 diff --git a/mysqlcppconn/mysql-connector-cpp.patch b/mysqlcppconn/mysql-connector-cpp.patch index b71050435165..0575653cedeb 100644 --- a/mysqlcppconn/mysql-connector-cpp.patch +++ b/mysqlcppconn/mysql-connector-cpp.patch @@ -350,12 +350,6 @@ #include <stack> #include "mysql_util.h" ---- misc/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:17:23.640625000 +0200 -+++ misc/build/mysql-connector-cpp/driver/nativeapi/binding_config.h 2009-08-14 10:13:50.359375000 +0200 -@@ -1 +1,2 @@ --dummy -+#define HAVE_DLFCN_H 1 -+//#define MYSQLCLIENT_STATIC_BINDING 1 --- misc/mysql-connector-cpp/driver/nativeapi/makefile.mk 2009-08-17 21:32:53.694119382 +0200 +++ misc/build/mysql-connector-cpp/driver/nativeapi/makefile.mk 2009-08-17 21:32:50.534346360 +0200 @@ -1 +1,23 @@ |