1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-08 14:02:17 +03:00
Commit Graph

18 Commits

Author SHA1 Message Date
Georg Richter
74a405d977 Fixed cmake warning 2021-06-16 15:10:04 +02:00
Georg Richter
7e39b85ab1 CONC-554: man pages for Connector/C
man pages for Connector/C can be found in the man subdirectory
of Connector/C source tree.

The man pages are created from the Connector/C wiki using pandoc
utility and the create_man python script.
2021-06-08 17:37:58 +02:00
Sergei Golubchik
6e78f124e0 cmake: use MESSAGE1, not MESSAGE 2020-04-07 22:10:48 +02:00
Otto Kekäläinen
28e1467475 CONC-456: Introduce INSTALL_PLUGINDIR_CLIENT
If there is a INSTALL_PLUGINDIR_CLIENT it will override whatever value
INSTALL_PLUGINDIR had. This is useful in MariaDB Server builds where this
repository exists as a git submodule in directory libmariadb/.

Normally, when a INSTALL_PLUGINDIR is set (which happens in the server) it
will override whatever values are in the client library. The client
library does define its own layout for INSTALL_LAYOUT=DEB, but it is
near useless, since the values are the same as in the default, apart for
INSTALL_LIBDIR, which points to /usr/lib/<arch>/libmariadb3/plugins, but
is overridden. With this new flag, it will not be overridden, and will
actually be set as we want it to be in new Debian builds.

Why /usr/lib/<arch>/libmariadb3/plugins?
- <arch>, e.g. x86_64-linux-gnu, is needed to allow co-installation of
  32-bit and 64-bit on Debian, and is relevant for libmariadb3 pacakge.
- The "libmariadb" part separates these client library plugins from the
  server plugins, which are now in /usr/lib/*/mysql/plugins, but likely
  in /usr/lib/*/mariadb/plugins in the future, and at that point we don't
  want them to get mixed with the client ones.
- The "3" in in "libmariadb3/plugins" is needed since the libmariadb3 can
  in far future be co-installed with package libmariadb4, since there could
  be on a running system programs built either against libmariadb3 or
  libmariadb4, at least during some transitioning period. When different
  versions of a package are co-installable, both the pacakge name and the
  file paths need to have a version component.
  Note that package libmariadb-dev does not have a version nor versioned
  paths, as for any given point in time when new builds are made, they
  are always made against the latest library version.

In addition, the PLUGINDIR_DEB option is removed since to our knowledge
nothing ever used it and it is thus obsolete.

Is this backwards compatible?
- Since the next release will be 3.1.8 (a minor release) all changes need
  to be fully backwards compatible.
- The version 3.1.8 will be included in all new MariaDB versions 10.2,
  10.3, 10.4 and 10.5. Of these, only 10.5 is under development and allows
  functional changes to be made. This means, that only in MariaD 10.5 there
  can be paths changed. Since this is a new option introduced, and in 10.5
  the option to use CONC_INSTALL_LAYOUT=DEB will be introduced, this code
  path is only active in MariaDB 10.5 and later with MariaDB Connector C
  3.1.8 or later. This has no effect on 10.2, 10.3 and 10.4, and is thus
  safe to apply.

This also fixes CONC-304, which was partially already fixed, but never
applied in server builds due to the same buggy build flag handling.

In addition, some line ending whitespace was removed.

Change tested with full builds of both the client and server and comparing
full deb file listings:

$ diff -u filelist-ad1a0660dfd.log filelist-1f57e8a0f64.log
--- filelist-ad1a0660dfd.log	2020-03-26 22:04:19.821001386 +0200
+++ filelist-1f57e8a0f64.log	2020-03-27 00:02:12.156576964 +0200
@@ -2,13 +2,13 @@
 drwxr-xr-x root/root ./
 drwxr-xr-x root/root ./usr/
 drwxr-xr-x root/root ./usr/lib/
-drwxr-xr-x root/root ./usr/lib/mysql/
-drwxr-xr-x root/root ./usr/lib/mysql/plugin/
--rw-r--r-- root/root ./usr/lib/mysql/plugin/client_ed25519.so
--rw-r--r-- root/root ./usr/lib/mysql/plugin/dialog.so
--rw-r--r-- root/root ./usr/lib/mysql/plugin/mysql_clear_password.so
--rw-r--r-- root/root ./usr/lib/mysql/plugin/sha256_password.so
 drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/
+drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/
+drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/client_ed25519.so
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/dialog.so
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/mysql_clear_password.so
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/sha256_password.so
 -rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb.so.3
 drwxr-xr-x root/root ./usr/share/
 drwxr-xr-x root/root ./usr/share/doc/
@@ -514,7 +514,8 @@
 -rw-r--r-- root/root ./usr/include/mariadb/server/typelib.h
 drwxr-xr-x root/root ./usr/lib/
 drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/
--rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadbclient.a
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb.a
+lrwxrwxrwx root/root ./usr/lib/x86_64-linux-gnu/libmariadbclient.a
 lrwxrwxrwx root/root ./usr/lib/x86_64-linux-gnu/libmariadbclient.so
 lrwxrwxrwx root/root ./usr/lib/x86_64-linux-gnu/libmariadb.so
 -rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmysqlservices.a
@@ -741,9 +742,10 @@
 drwxr-xr-x root/root ./
 drwxr-xr-x root/root ./usr/
 drwxr-xr-x root/root ./usr/lib/
-drwxr-xr-x root/root ./usr/lib/mysql/
-drwxr-xr-x root/root ./usr/lib/mysql/plugin/
--rw-r--r-- root/root ./usr/lib/mysql/plugin/auth_gssapi_client.so
+drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/
+drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/
+drwxr-xr-x root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/
+-rw-r--r-- root/root ./usr/lib/x86_64-linux-gnu/libmariadb3/plugin/auth_gssapi_client.so
 drwxr-xr-x root/root ./usr/share/
 drwxr-xr-x root/root ./usr/share/doc/
 drwxr-xr-x root/root ./usr/share/doc/mariadb-plugin-gssapi-client/


The MariaDB Server part will be fixed in MDEV-22053.

When and in what order can this be rolled out?
- This change only affects server builds once the MDEV-22053 is fixed, so
  this can be merged on the MariaDB Connector C at any time.
- The server MDEV-22053 can be fixed at any time, as it only starts to
  apply to the server once MariaDB Connector C 3.1.8 is released _and_
  the MariaDB Server source code submodule libmariadb is updated, at which
  point the Debian packaging is affected and needs to be updated.

Are there resources to carry out this change?
- Otto made this change and will also fix MDEV-22053.
- Otto will update MariaDB Server 10.5 packaging as soon as MariaDB
  Connector C 3.1.8 is out and updated as submodule in server.
2020-03-28 11:43:10 +02:00
Georg Richter
3586036069 As requested by Otto Käkelainen the directory for client plugins in Debian
should  contain also the major version number.
2020-03-26 19:59:19 +01:00
Georg Richter
11a2d035dd CONC-431: Use windows crypto libraries on Windows platforms
By default Windows builds now use the native system crypto libraries used
by ed25519, caching_sha2_password and sha256_password authentication plugins.
Even if configuration option WITH_SSL=OFF was specified (or no TLS library was found) authentication plugins using crypto will be available.
2019-08-01 14:02:04 +02:00
Georg Richter
4964fae885 Fix for CONC-271:
This bug was aöready fixed by commit 843c492, but overwritten by an incorrect merge
from server branch of Connector/C.
2019-01-25 08:13:57 +01:00
Sergei Golubchik
44b21bf642 install libmariadb.pc in the package-dependent location 2018-11-14 13:55:28 +01:00
Sergei Golubchik
d0582ea02f debian packaging fixes
early return prevents LIBMARIADB_STATIC_NAME from being set
2018-08-12 14:50:14 +02:00
Georg Richter
eb64582b68 Debian layout changes/fixes 2018-07-25 09:33:53 +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
Sergei Golubchik
b9d6bea263 fix the installation layout 2016-09-13 14:28:23 +02: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
f0601e0e40 Manual merge from 2.3 branch:
put cmake helper scripts under new BSD license
2016-07-09 10:53:09 +02:00
Georg Richter
af04caf260 Fix for CONC-132: Set SUFFIX and PREFIX_INSTALL_DIR when specified 2015-06-27 08:52:47 +02:00
Georg Richter
a38bd7c7e8 Fixed hardcoded path for default locations 2015-01-16 13:17:51 +01:00
Georg Richter
cd16280a3f - mysql_load_plugin_v supports now the environment variable MARIADB_PLUGIN_DIR
to load plugins from a different destination than PLUGINDIR.

- added dialog plugin for authentication (e.g. PAM). If an application provides
  it's own dialog function, the name must be mariadb_auth_dialog (or for libmysql
  compatibility mysql_authentication_dialog_ask).
  Windows-Todo: 
  1. provide a simple GUI dialog on windows, in case opening the console failed.
  2. convert data from console code page to character set of current connection
2014-12-11 09:47:49 +01:00
Georg Richter
14c954c51c More dynamic solution for CONC-107.
Cmake now supports the following options:
       -DINSTALL_LAYOUT=DEFAULT or RPM
       -DINSTALL_LIB_DIR
       -DINSTALL_INCLUDE_DIR
       -DINSTALL_DOCS_DIR
       -DINSTALL_PLUGINS_DIR
       -DINSTALL_BIN_DIR
2014-11-04 16:30:41 +01:00