1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Fix embedded innodb_plugin after 560799ebd8

wsrep_certification_rules: Define as a weak global symbol.
While there are separate _embedded.a for statically
linked storage engine plugins, there is only one ha_innodb.so
which is supposed to work with both values of WITH_WSREP.

The merge from 10.0-galera introduced a reference to a global
variable that is only defined when the server is built WITH_WSREP.
We must define that symbol as weak global, so that when
a dynamically linked InnoDB or XtraDB is used with the embedded
server (which never includes write-set replication patches),
the variable will be read as 0, instead of causing a failure to
load the InnoDB or XtraDB plugin.
This commit is contained in:
Marko Mäkelä
2019-02-02 12:49:04 +02:00
parent a193c5720e
commit c1e1764fc4
3 changed files with 15 additions and 3 deletions

View File

@ -21,6 +21,10 @@ enum enum_wsrep_certification_rules {
WSREP_CERTIFICATION_RULES_OPTIMIZED
};
extern ulong wsrep_certification_rules;
/* This is intentionally declared as a weak global symbol, so that
the same ha_innodb.so can be used with the embedded server
(which does not link to the definition of this variable)
and with the regular server built WITH_WSREP. */
extern ulong wsrep_certification_rules __attribute__((weak));
#endif /* WSREP_MYSQLD_C_H */