Commit c20979b1 authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

MDEV-9601 Build client plugins, also for the cmake client-only build

(-DWITHOUT_SERVER=1)
parent d9c640aa
......@@ -366,11 +366,9 @@ IF(WITH_UNIT_TESTS)
ENDIF()
ENDIF()
IF(NOT WITHOUT_SERVER)
SET (MYSQLD_STATIC_PLUGIN_LIBS "" CACHE INTERNAL "")
# Add storage engines and plugins.
CONFIGURE_PLUGINS()
ENDIF()
SET (MYSQLD_STATIC_PLUGIN_LIBS "" CACHE INTERNAL "")
# Add storage engines and plugins.
CONFIGURE_PLUGINS()
ADD_SUBDIRECTORY(include)
ADD_SUBDIRECTORY(dbug)
......@@ -400,6 +398,10 @@ IF(NOT WITHOUT_SERVER)
ADD_SUBDIRECTORY(mysql-test)
ADD_SUBDIRECTORY(mysql-test/lib/My/SafeProcess)
ADD_SUBDIRECTORY(sql-bench)
IF(WIN32)
ADD_SUBDIRECTORY(win/upgrade_wizard)
ADD_SUBDIRECTORY(win/packaging)
ENDIF()
ENDIF()
IF(UNIX)
......@@ -409,10 +411,7 @@ ENDIF()
INCLUDE(cmake/abi_check.cmake)
INCLUDE(cmake/tags.cmake)
IF(WIN32)
ADD_SUBDIRECTORY(win/upgrade_wizard)
ADD_SUBDIRECTORY(win/packaging)
ENDIF()
INCLUDE(for_clients)
......
......@@ -28,12 +28,15 @@ INCLUDE(${MYSQL_CMAKE_SCRIPT_DIR}/cmake_parse_arguments.cmake)
# [LINK_LIBRARIES lib1...libN]
# [DEPENDENCIES target1...targetN]
MACRO(MYSQL_ADD_PLUGIN)
FUNCTION(MYSQL_ADD_PLUGIN)
MYSQL_PARSE_ARGUMENTS(ARG
"LINK_LIBRARIES;DEPENDENCIES;MODULE_OUTPUT_NAME;STATIC_OUTPUT_NAME;COMPONENT;CONFIG"
"STORAGE_ENGINE;STATIC_ONLY;MODULE_ONLY;MANDATORY;DEFAULT;DISABLED;RECOMPILE_FOR_EMBEDDED;CLIENT"
${ARGN}
)
IF(WITHOUT_SERVER AND NOT ARG_CLIENT)
RETURN()
ENDIF()
# Add common include directories
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include
......@@ -235,14 +238,16 @@ MACRO(MYSQL_ADD_PLUGIN)
IF(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/mysql-test")
INSTALL_MYSQL_TEST("${CMAKE_CURRENT_SOURCE_DIR}/mysql-test/" "plugin/${subpath}")
ENDIF()
ENDMACRO()
ENDFUNCTION()
# Add all CMake projects under storage and plugin
# subdirectories, configure sql_builtins.cc
MACRO(CONFIGURE_PLUGINS)
IF(NOT WITHOUT_SERVER)
FILE(GLOB dirs_storage ${CMAKE_SOURCE_DIR}/storage/*)
ENDIF()
FILE(GLOB dirs_plugin ${CMAKE_SOURCE_DIR}/plugin/*)
FOREACH(dir ${dirs_storage} ${dirs_plugin})
IF (EXISTS ${dir}/CMakeLists.txt)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment