Use MARIADB_BASE_VERSION instead of LIBMARIADB to detect Maria DB

It was discovered that MariaDB 10 didn't define LIBMARIADB leading
to compilation errors of MySQL DLZ modules on Debian stretch.

Use MARIADB_BASE_VERSION instead which is defined in all tested MariaDB
versions.

(cherry picked from commit 5835aae694)
This commit is contained in:
Ondřej Surý 2022-04-28 13:37:40 +02:00 committed by Ondřej Surý
parent d04fb79f1f
commit cf4e08d9cb
2 changed files with 4 additions and 4 deletions

View file

@ -44,9 +44,9 @@
#include <dlz_minimal.h>
#include <dlz_pthread.h>
#if !defined(LIBMARIADB) && MYSQL_VERSION_ID >= 80000
#if !defined(MARIADB_BASE_VERSION) && MYSQL_VERSION_ID >= 80000
typedef bool my_bool;
#endif /* !defined(LIBMARIADB) && MYSQL_VERSION_ID >= 80000 */
#endif /* !defined(MARIADB_BASE_VERSION) && MYSQL_VERSION_ID >= 80000 */
#define dbc_search_limit 30
#define ALLNODES 1

View file

@ -56,9 +56,9 @@
#include <dlz_minimal.h>
#include <dlz_pthread.h>
#if !defined(LIBMARIADB) && MYSQL_VERSION_ID >= 80000
#if !defined(MARIADB_BASE_VERSION) && MYSQL_VERSION_ID >= 80000
typedef bool my_bool;
#endif /* !defined(LIBMARIADB) && MYSQL_VERSION_ID >= 80000 */
#endif /* !defined(MARIADB_BASE_VERSION) && MYSQL_VERSION_ID >= 80000 */
/*
* The SQL queries that will be used for lookups and updates are defined