1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-09-11 08:30:59 +03:00
Commit Graph

39 Commits

Author SHA1 Message Date
Sergei Golubchik
61ef765c43 change plugin TYPE in the REGISTER_PLUGIN to something useful
it's currently unused
2024-10-17 10:00:31 +02:00
Georg Richter
21b91ccf41 removed aurora plugin from CMakeLists.txt 2022-02-04 15:14:00 +01:00
Georg Richter
a1fb2b5e22 Removed connection plugin 'aurora' 2020-11-18 11:33:28 +01:00
Oleksandr Byelkin
895dcb61e3 C preprocessor defines fix 2020-06-04 16:49:21 +02:00
luz.paz
b2e6ed0295 Fixes misc. typos
found via `codespell -q 3`
2018-04-13 07:30:23 +02:00
Georg Richter
50d48e91fa Reworked plugin interface
Plugin configuration happens now in CMakeLists.txt files in corresponding plugin directories.

plugins.cmake now contains REGISTER_PLUGIN_FUNCTION which accepts the following parameters:
  - TARGET: the name of the plugin (dynamic plugins will be named ${TARGET}.so (or .dll)
  - SOURCES: source files
  - LIBRARIES: additional libraries for linking
  - INCLUDES: include directories
  - CONFIGURATIONS: possible plugin configurations: valid arguments are DYNAMIC, STATIC, OFF
  - DEFAULT: default configuration (see CONFIGURATIONS)
  - COMPILE_OPTIONS: compiler flags

The default plugin configuration can be specified via cmake parameter -DCLIENT_PLUGIN_${TARGET}=[DYNAMIC|STATIC|OFF]
2018-04-07 07:14:43 +02:00
Georg Richter
87e861c360 client side implemetation for MDEV-10340:
int STDCALL mysql_reset_connection(MYSQL *mysql)
2016-12-29 19:10:35 +01:00
Georg Richter
aabaac04aa Plugin fixes
- include ma_errmsg.h if plugin is built dynamically
- trace_example fixes
2016-11-24 08:56:27 +01:00
Georg Richter
967b2830d8 renamed ma_errmsg.h back to errmsg.h 2016-11-16 18:13:59 +01:00
Georg Richter
6306c9f46b - removed COM_MULTI from options
COM_MULTI is now available for internal use only, e.g. in
  mariadb_stmt_execute_direct
2016-10-20 08:47:51 +02:00
Vladislav Vaintroub
e34a595ce2 MDEV-11008 Connector/C integration does not respect INSTALL_LIBDIR
or INSTALL_DOCDIR

Changed C/C to use the same cmake variables for
INSTALL_LIBDIR, INSTALL_BINDIR, INSTALL_INCLUDEDIR, INSTALL_PLUGINDIR


Small cleanups (remove -l/full/path/to/libc.so from mariadb_config output)
2016-10-12 11:58:53 +00:00
Vladislav Vaintroub
da8977d670 Merge branch 'master' into serg-integr 2016-09-12 11:47:14 +00:00
Vladislav Vaintroub
38b5e400da C/C integration : Fix mysql_test_client test
- #include <stdlib.h> for strtod and other prototypes
- remove ma_config_win.h as it  redefines things from ma_config.h
- fix compile warnings
2016-09-07 17:14:02 +00:00
Sergei Golubchik
7a787b1e3e C/C integration in MariaDB Server builds
* make is usable as a CMake sub-project
  * put options in a separate namespace
  * but use parent project values when specified
* always specify COMPONENT when INSTALLing
* don't use PROJECT_SOURCE_DIR/PROJECT_BINARY_DIR

Also

* fix out-of-source builds (don't generate files
  in the CMAKE_SOURCE_DIR, always do it in CMAKE_BINARY_DIR)
* make subsequence cmake runs less verbose, use MESSAGE1
  to avoid repeating messages that didn't change
2016-09-05 19:15:58 +02:00
Georg Richter
9f88e25fd6 Compiler warning fixes 2016-09-03 12:46:50 +02:00
GeorgyKirichenko
56505d8fb6 Use PROJECT_SOURCE_DIR instead of CMAKE_SOURCE_DIR. Client library
can be used as subdirectory in another cmake project.
2016-04-27 17:54:07 +03:00
Georg Richter
21be8f4eef Moved connection_handler to mysql->extension 2016-03-29 09:44:03 +02:00
Georg Richter
2f6791115f changed plugin library types from SHARED to MODULE
Fixed float/double/decimal converion for prepared statements:
  since _gcvt (Windows) and gcvt (*nix) deliver different results
  we use now dtoa.c from server package, which is licensed under
  LGPL.
2016-03-11 07:08:34 +01:00
Georg Richter
7a27c4cd11 Build fix for MacOSX 2016-02-29 15:38:37 +01:00
Georg Richter
8620b754ea Added missing error messages for wrong protocol
moved connection handler into net->extension (ABI break)
2016-02-23 13:50:14 +01:00
Georg Richter
d68b48f954 10.2 integration fixes
- changed plugin API to avoid crashes: Oracle/MariaDB changed
    structure several times without updating interface version.
  - ABI fixes: moved additional net items to net->extension (connection
    handler and com_multi buffer)
2016-02-22 11:37:13 +01:00
Georg Richter
4ca933bb81 Global cleanup:
removed global locks
  removed dead code and files
  removed dbug
2016-02-08 18:43:02 +01:00
Georg Richter
7c7fae2286 Added include path for connection plugins 2016-01-18 10:42:12 +01:00
Georg Richter
f8912935b1 - Fixed several aurora plugin crashes (after reconnect)
- moved mysql->reconnect to mysql->options.reconnect
2016-01-16 07:04:28 +01:00
Georg Richter
77fec5c58f Fix for aurora: remember options when trying to connect inside
plugin to avoid double free of options
2016-01-11 08:58:15 +01:00
Georg Richter
43c9aec83d Aurora fixes: use mariadb_api structure for calling api functions. 2016-01-10 17:21:03 +01:00
Georg Richter
f62a2e0270 Fixed several memory leaks in ma_ssl.c 2016-01-07 13:23:28 +01:00
Georg Richter
b5cf443681 Windows fixes for remote_io plugin 2016-01-04 10:02:10 +01:00
Georg Richter
5f98f7710a Fixed mysql_api methods: On Windows functions need to be declared with
STDCALL.
Fixed warning in my_context.h
2015-12-29 20:37:18 +01:00
Georg Richter
46a975bd04 Added st_mariadb_api structure which contains api definition for use
in dynamic plugins
2015-12-28 09:00:24 +01:00
Georg Richter
d73e4c23a2 Added new API function mysql_get_info/mysql_get_infov which retrieves
global or connection dependent information:

mysql_get_infov(MYSQL *mysql, enum mariadb_value value, void *arg, ...)

the following value types are supported:
    MARIADB_CHARSET_ID (requires numeric 4th parameter)
    MARIADB_CHARSET_INFO (requires string 4th parameter)
    MARIADB_CHARSET_NAME
    MARIADB_CLIENT_ERRORS
    MARIADB_CLIENT_VERSION
    MARIADB_CLIENT_VERSION_ID
    MARIADB_CONNECTION_ASYNC_TIMEOUT
    MARIADB_CONNECTION_ASYNC_TIMEOUT_MS
    MARIADB_CONNECTION_HOST
    MARIADB_CONNECTION_INFO
    MARIADB_CONNECTION_PORT
    MARIADB_CONNECTION_PROTOCOL_VERSION_ID
    MARIADB_CONNECTION_PVIO_TYPE
    MARIADB_CONNECTION_SCHEMA
    MARIADB_CONNECTION_SERVER_TYPE
    MARIADB_CONNECTION_SERVER_VERSION
    MARIADB_CONNECTION_SERVER_VERSION_ID
    MARIADB_CONNECTION_SOCKET
    MARIADB_CONNECTION_SSL_CIPHER
    MARIADB_CONNECTION_SSL_VERSION
    MARIADB_CONNECTION_SSL_VERSION_ID
    MARIADB_CONNECTION_TYPE
    MARIADB_CONNECTION_UNIX_SOCKET
    MARIADB_CONNECTION_USER
    MARIADB_MAX_ALLOWED_PACKET
    MARIADB_NET_BUFFER_LENGTH

MARIADB_CONNECTION prefix indicates that a valid connection handle has
to be passed as first parameter.
2015-12-28 07:32:53 +01:00
Georg Richter
d68c7dae95 Fixed warning on Windows 64-bit build 2015-12-19 17:07:10 +01:00
Georg Richter
bec245a913 Initial aurora implementation 2015-12-10 12:52:51 +01:00
Georg Richter
587f6d8c63 Added version info support for Windows:
For adding version_info use the macro SET_VERSION_INFO.
The following variable parameters are supported:
  TARGET:target_name
  SOURCE_FILE:source_file_name
  FILE_TYPE:VFT_APP,VFT_Dll or VT_STATIC_LIB
  ORIGINAL_FILE_NAME:exe,dll or lib filename
  FILE_DESCRIPTION:short description of the file
2015-11-10 11:10:28 +01:00
Georg Richter
dd29c4abec Renamed MYSQL_COM_* to COM_
changed default schema for tests to test_c
2015-11-02 15:19:10 +01:00
Georg Richter
7500f37150 - Renamed cio to pvio (pluggable virtual IO)
- minor fixes in windows schannel
2015-10-27 10:24:48 +01:00
Georg Richter
5827c04551 Windows build fixes 2015-10-19 09:52:30 +02:00
Georg Richter
ba301da127 Fixed windows build 2015-10-05 08:06:48 +02:00
Georg Richter
74e62c2892 Merge remote-tracking branch 'origin/master' into cio
Conflicts:
	CMakeLists.txt
	include/mysql/client_plugin.h
	libmariadb/client_plugin.c.in
	libmariadb/libmariadb.c
	libmariadb/ma_secure.c
	libmariadb/my_malloc.c
	libmariadb/net.c
	plugins/io/CMakeLists.txt
	unittest/libmariadb/misc.c
2015-10-02 12:28:54 +02:00