Description:
The MYSQL_ADD_PLUGIN macro has a spelling error causing the MYSQL_SERVER define not to be defined. This causes the storage engine plugins to be compiled without MYSQL_SERVER defined and thus may get a different set of function signatures, functions and symbols unless the source of the plugins themself define the MYSQL_SERVER define.
The plugin.cmake intends to add the MYSQL_SERVER define to the storage engine target but fails to do so since there is a spelling error of the property COMPILE_DEFINITIONS it want to set.
The embedded target properly get both MYSQL_SERVER and EMBEDDED_LIBRARY defined as intended. Similar spelling error there would probably have been noticed.
How to repeat:
diff --git a/cmake/plugin.cmake b/cmake/plugin.cmake
index eb968c7..8a4c89f 100644
--- a/cmake/plugin.cmake
+++ b/cmake/plugin.cmake
@@ -123,6 +123,7 @@ MACRO(MYSQL_ADD_PLUGIN)
IF (WITH_${plugin} AND NOT ARG_MODULE_ONLY)
ADD_CONVENIENCE_LIBRARY(${target} STATIC ${SOURCES})
SET_TARGET_PROPERTIES(${target} PROPERTIES COMPILE_DEFINITONS "MYSQL_SERVER")
+ ^
DTRACE_INSTRUMENT(${target})
ADD_DEPENDENCIES(${target} GenError ${ARG_DEPENDENCIES})
IF(WITH_EMBEDDED_SERVER AND NOT ARG_NOT_FOR_EMBEDDED)
Suggested fix:
Fix the spelling error of COMPILE_DEFINITIONS