Commit 751ebe44 authored by Heinz Wiesinger's avatar Heinz Wiesinger Committed by Vicențiu Ciorbaru

Add feature summary at the end of cmake.

This gives a short overview over found/missing dependencies as well
as enabled/disabled features.

Initial author Heinz Wiesinger <heinz@m2mobi.com>
Additions by Vicențiu Ciorbaru <vicentiu@mariadb.org>
* Report all plugins enabled via MYSQL_ADD_PLUGIN
* Simplify code. Eliminate duplication by making use of WITH_xxx
  variable values to set feature "ON" / "OFF" state.

Reviewed by: wlad@mariadb.com (code details) serg@mariadb.com (the idea)
parent 2b017367
...@@ -147,6 +147,7 @@ IF (NOT CPACK_GENERATOR) ...@@ -147,6 +147,7 @@ IF (NOT CPACK_GENERATOR)
ENDIF(WIN32) ENDIF(WIN32)
ENDIF(NOT CPACK_GENERATOR) ENDIF(NOT CPACK_GENERATOR)
INCLUDE(FeatureSummary)
INCLUDE(misc) INCLUDE(misc)
INCLUDE(mysql_version) INCLUDE(mysql_version)
INCLUDE(cpack_source_ignore_files) INCLUDE(cpack_source_ignore_files)
...@@ -418,11 +419,14 @@ ADD_SUBDIRECTORY(sql/share) ...@@ -418,11 +419,14 @@ ADD_SUBDIRECTORY(sql/share)
IF(NOT WITHOUT_SERVER) IF(NOT WITHOUT_SERVER)
ADD_SUBDIRECTORY(tests) ADD_SUBDIRECTORY(tests)
ADD_SUBDIRECTORY(sql) ADD_SUBDIRECTORY(sql)
OPTION (WITH_EMBEDDED_SERVER "Compile MySQL with embedded server" OFF) OPTION (WITH_EMBEDDED_SERVER "Compile MariaDB with embedded server" OFF)
IF(WITH_EMBEDDED_SERVER) IF(WITH_EMBEDDED_SERVER)
ADD_SUBDIRECTORY(libmysqld) ADD_SUBDIRECTORY(libmysqld)
ADD_SUBDIRECTORY(libmysqld/examples) ADD_SUBDIRECTORY(libmysqld/examples)
ENDIF(WITH_EMBEDDED_SERVER) ENDIF(WITH_EMBEDDED_SERVER)
IF(NOT WIN32)
ADD_FEATURE_INFO(EMBEDDED_SERVER WITH_EMBEDDED_SERVER "Embedded MariaDB Server Library")
ENDIF()
IF(WITH_WSREP) IF(WITH_WSREP)
ADD_SUBDIRECTORY(wsrep) ADD_SUBDIRECTORY(wsrep)
...@@ -507,6 +511,13 @@ IF(WIN32 AND SIGNCODE) ...@@ -507,6 +511,13 @@ IF(WIN32 AND SIGNCODE)
INSTALL(SCRIPT ${PROJECT_BINARY_DIR}/sign.cmake) INSTALL(SCRIPT ${PROJECT_BINARY_DIR}/sign.cmake)
ENDIF() ENDIF()
FEATURE_SUMMARY(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES VAR MARIADB_FEATURE_SUMMARY)
OPTION(FEATURE_SUMMARY "Print feature summary at the end of configure step" ON)
IF (FEATURE_SUMMARY)
MESSAGE_ONCE(SUMMARY "${MARIADB_FEATURE_SUMMARY}")
ENDIF()
IF(NON_DISTRIBUTABLE_WARNING) IF(NON_DISTRIBUTABLE_WARNING)
MESSAGE(WARNING " MESSAGE(WARNING "
You have linked MariaDB with ${NON_DISTRIBUTABLE_WARNING} libraries! You may not distribute the resulting binary. If you do, you will put yourself into a legal problem with the Free Software Foundation.") You have linked MariaDB with ${NON_DISTRIBUTABLE_WARNING} libraries! You may not distribute the resulting binary. If you do, you will put yourself into a legal problem with the Free Software Foundation.")
......
...@@ -37,5 +37,6 @@ MACRO (CHECK_JEMALLOC) ...@@ -37,5 +37,6 @@ MACRO (CHECK_JEMALLOC)
IF (NOT LIBJEMALLOC AND NOT WITH_JEMALLOC STREQUAL "auto") IF (NOT LIBJEMALLOC AND NOT WITH_JEMALLOC STREQUAL "auto")
MESSAGE(FATAL_ERROR "jemalloc is not found") MESSAGE(FATAL_ERROR "jemalloc is not found")
ENDIF() ENDIF()
ADD_FEATURE_INFO(JEMALLOC LIBJEMALLOC "Use the JeMalloc memory allocator")
ENDIF() ENDIF()
ENDMACRO() ENDMACRO()
...@@ -31,6 +31,7 @@ MACRO (MYSQL_CHECK_NUMA) ...@@ -31,6 +31,7 @@ MACRO (MYSQL_CHECK_NUMA)
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(NUMA HAVE_LIBNUMA "NUMA memory allocation policy")
IF(WITH_NUMA AND NOT HAVE_LIBNUMA) IF(WITH_NUMA AND NOT HAVE_LIBNUMA)
# Forget it in cache, abort the build. # Forget it in cache, abort the build.
UNSET(WITH_NUMA CACHE) UNSET(WITH_NUMA CACHE)
......
...@@ -49,7 +49,7 @@ MACRO(MYSQL_ADD_PLUGIN) ...@@ -49,7 +49,7 @@ MACRO(MYSQL_ADD_PLUGIN)
LIST(REMOVE_AT SOURCES 0) LIST(REMOVE_AT SOURCES 0)
STRING(TOUPPER ${plugin} plugin) STRING(TOUPPER ${plugin} plugin)
STRING(TOLOWER ${plugin} target) STRING(TOLOWER ${plugin} target)
IF (ARG_MANDATORY) IF (ARG_MANDATORY)
UNSET(PLUGIN_${plugin} CACHE) UNSET(PLUGIN_${plugin} CACHE)
SET(PLUGIN_${plugin} "YES") SET(PLUGIN_${plugin} "YES")
...@@ -110,11 +110,11 @@ MACRO(MYSQL_ADD_PLUGIN) ...@@ -110,11 +110,11 @@ MACRO(MYSQL_ADD_PLUGIN)
SET(with_var "WITH_${plugin}") SET(with_var "WITH_${plugin}")
ENDIF() ENDIF()
UNSET(${with_var} CACHE) UNSET(${with_var} CACHE)
IF(NOT ARG_DEPENDENCIES) IF(NOT ARG_DEPENDENCIES)
SET(ARG_DEPENDENCIES) SET(ARG_DEPENDENCIES)
ENDIF() ENDIF()
IF(NOT ARG_MODULE_OUTPUT_NAME) IF(NOT ARG_MODULE_OUTPUT_NAME)
IF(ARG_STORAGE_ENGINE) IF(ARG_STORAGE_ENGINE)
SET(ARG_MODULE_OUTPUT_NAME "ha_${target}") SET(ARG_MODULE_OUTPUT_NAME "ha_${target}")
...@@ -257,6 +257,16 @@ MACRO(MYSQL_ADD_PLUGIN) ...@@ -257,6 +257,16 @@ MACRO(MYSQL_ADD_PLUGIN)
INSTALL_MYSQL_TEST("${CMAKE_CURRENT_SOURCE_DIR}/mysql-test/" "plugin/${subpath}") INSTALL_MYSQL_TEST("${CMAKE_CURRENT_SOURCE_DIR}/mysql-test/" "plugin/${subpath}")
ENDIF() ENDIF()
GET_TARGET_PROPERTY(plugin_type ${target} TYPE)
STRING(REGEX REPLACE "_LIBRARY$" "" plugin_type ${plugin_type})
STRING(REGEX REPLACE "^NO$" "" plugin_type ${plugin_type})
IF(ARG_STORAGE_ENGINE)
ADD_FEATURE_INFO(${plugin} PLUGIN_${plugin} "Storage Engine ${plugin_type}")
ELSEIF(ARG_CLIENT)
ADD_FEATURE_INFO(${plugin} PLUGIN_${plugin} "Client plugin ${plugin_type}")
ELSE()
ADD_FEATURE_INFO(${plugin} PLUGIN_${plugin} "Server plugin ${plugin_type}")
ENDIF()
ENDIF(NOT WITHOUT_SERVER OR ARG_CLIENT) ENDIF(NOT WITHOUT_SERVER OR ARG_CLIENT)
ENDMACRO() ENDMACRO()
......
...@@ -52,7 +52,7 @@ MACRO (MYSQL_CHECK_MULTIBYTE) ...@@ -52,7 +52,7 @@ MACRO (MYSQL_CHECK_MULTIBYTE)
ENDMACRO() ENDMACRO()
MACRO (FIND_CURSES) MACRO (FIND_CURSES)
FIND_PACKAGE(Curses) FIND_PACKAGE(Curses REQUIRED)
MARK_AS_ADVANCED(CURSES_CURSES_H_PATH CURSES_FORM_LIBRARY CURSES_HAVE_CURSES_H) MARK_AS_ADVANCED(CURSES_CURSES_H_PATH CURSES_FORM_LIBRARY CURSES_HAVE_CURSES_H)
IF(NOT CURSES_FOUND) IF(NOT CURSES_FOUND)
SET(ERRORMSG "Curses library not found. Please install appropriate package, SET(ERRORMSG "Curses library not found. Please install appropriate package,
......
...@@ -126,6 +126,7 @@ MACRO (MYSQL_CHECK_SSL) ...@@ -126,6 +126,7 @@ MACRO (MYSQL_CHECK_SSL)
ENDIF() ENDIF()
ENDIF() ENDIF()
FIND_PACKAGE(OpenSSL) FIND_PACKAGE(OpenSSL)
SET_PACKAGE_PROPERTIES(OpenSSL PROPERTIES TYPE RECOMMENDED)
IF(OPENSSL_FOUND) IF(OPENSSL_FOUND)
SET(OPENSSL_LIBRARY ${OPENSSL_SSL_LIBRARY}) SET(OPENSSL_LIBRARY ${OPENSSL_SSL_LIBRARY})
SET(SSL_SOURCES "") SET(SSL_SOURCES "")
......
...@@ -63,5 +63,6 @@ MACRO(CHECK_SYSTEMD) ...@@ -63,5 +63,6 @@ MACRO(CHECK_SYSTEMD)
ELSEIF(NOT WITH_SYSTEMD STREQUAL "no") ELSEIF(NOT WITH_SYSTEMD STREQUAL "no")
MESSAGE(FATAL_ERROR "Invalid value for WITH_SYSTEMD. Must be 'yes', 'no', or 'auto'.") MESSAGE(FATAL_ERROR "Invalid value for WITH_SYSTEMD. Must be 'yes', 'no', or 'auto'.")
ENDIF() ENDIF()
ADD_FEATURE_INFO(SYSTEMD LIBSYSTEMD "Systemd scripts and notification support")
ENDIF() ENDIF()
ENDMACRO() ENDMACRO()
...@@ -41,3 +41,6 @@ SET(WSREP_PROC_INFO ${WITH_WSREP}) ...@@ -41,3 +41,6 @@ SET(WSREP_PROC_INFO ${WITH_WSREP})
IF(WITH_WSREP) IF(WITH_WSREP)
SET(WSREP_PATCH_VERSION "wsrep_${WSREP_VERSION}") SET(WSREP_PATCH_VERSION "wsrep_${WSREP_VERSION}")
ENDIF() ENDIF()
IF (NOT WIN32)
ADD_FEATURE_INFO(WSREP WITH_WSREP "WSREP replication API (to use, e.g. Galera Replication library)")
ENDIF()
...@@ -161,6 +161,7 @@ IF(UNIX) ...@@ -161,6 +161,7 @@ IF(UNIX)
SET(LIBWRAP "wrap") SET(LIBWRAP "wrap")
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(LIBWRAP HAVE_LIBWRAP "Support for tcp wrappers")
ENDIF() ENDIF()
# #
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
OPTION(WITH_MARIABACKUP "Include mariabackup" ON) OPTION(WITH_MARIABACKUP "Include mariabackup" ON)
ADD_FEATURE_INFO(MARIABACKUP WITH_MARIABACKUP "MariaDB Backup Utility")
IF(NOT WITH_MARIABACKUP) IF(NOT WITH_MARIABACKUP)
RETURN() RETURN()
ENDIF() ENDIF()
......
...@@ -11,6 +11,7 @@ IF(USE_SSPI) ...@@ -11,6 +11,7 @@ IF(USE_SSPI)
ELSE() ELSE()
SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake) SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
FIND_PACKAGE(GSSAPI) FIND_PACKAGE(GSSAPI)
SET_PACKAGE_PROPERTIES(GSSAPI PROPERTIES TYPE OPTIONAL)
IF(GSSAPI_FOUND) IF(GSSAPI_FOUND)
INCLUDE_DIRECTORIES(${GSSAPI_INCS}) INCLUDE_DIRECTORIES(${GSSAPI_INCS})
ADD_DEFINITIONS(-DPLUGIN_GSSAPI) ADD_DEFINITIONS(-DPLUGIN_GSSAPI)
......
...@@ -13,6 +13,7 @@ ...@@ -13,6 +13,7 @@
# or if plugin is explicitly requested to build. Then bail out. # or if plugin is explicitly requested to build. Then bail out.
MACRO(SKIP_AWS_PLUGIN msg) MACRO(SKIP_AWS_PLUGIN msg)
MESSAGE_ONCE(SKIP_AWS_PLUGIN "Skip aws_key_management - ${msg}") MESSAGE_ONCE(SKIP_AWS_PLUGIN "Skip aws_key_management - ${msg}")
ADD_FEATURE_INFO(AWS_KEY_MANAGEMENT "OFF" "AWS Encryption Key Management Plugin")
RETURN() RETURN()
ENDMACRO() ENDMACRO()
SET(CMAKE_CXX_STANDARD 11) SET(CMAKE_CXX_STANDARD 11)
...@@ -76,6 +77,7 @@ ELSE() ...@@ -76,6 +77,7 @@ ELSE()
INCLUDE(ExternalProject) INCLUDE(ExternalProject)
IF(UNIX) IF(UNIX)
FIND_PACKAGE(CURL) FIND_PACKAGE(CURL)
SET_PACKAGE_PROPERTIES(CURL PROPERTIES TYPE REQUIRED)
IF(NOT CURL_FOUND) IF(NOT CURL_FOUND)
SKIP_AWS_PLUGIN("AWS C++ SDK requires libcurl development package") SKIP_AWS_PLUGIN("AWS C++ SDK requires libcurl development package")
ENDIF() ENDIF()
...@@ -86,10 +88,12 @@ ELSE() ...@@ -86,10 +88,12 @@ ELSE()
ENDIF() ENDIF()
IF(NOT APPLE) IF(NOT APPLE)
FIND_LIBRARY(UUID_LIBRARIES uuid) FIND_LIBRARY(UUID_LIBRARIES uuid)
SET_PACKAGE_PROPERTIES(UUID_LIBRARIES PROPERTIES TYPE REQUIRED)
IF(NOT UUID_LIBRARIES) IF(NOT UUID_LIBRARIES)
SKIP_AWS_PLUGIN("AWS C++ SDK requires uuid development package") SKIP_AWS_PLUGIN("AWS C++ SDK requires uuid development package")
ENDIF() ENDIF()
FIND_PACKAGE(OpenSSL) FIND_PACKAGE(OpenSSL)
SET_PACKAGE_PROPERTIES(OpenSSL PROPERTIES TYPE REQUIRED)
IF(NOT OPENSSL_FOUND) IF(NOT OPENSSL_FOUND)
SKIP_AWS_PLUGIN("AWS C++ SDK requires openssl development package") SKIP_AWS_PLUGIN("AWS C++ SDK requires openssl development package")
ENDIF() ENDIF()
...@@ -170,5 +174,7 @@ MYSQL_ADD_PLUGIN(aws_key_management aws_key_management_plugin.cc ...@@ -170,5 +174,7 @@ MYSQL_ADD_PLUGIN(aws_key_management aws_key_management_plugin.cc
COMPONENT aws-key-management) COMPONENT aws-key-management)
IF (TARGET aws_key_management) IF (TARGET aws_key_management)
SET(NON_DISTRIBUTABLE_WARNING "Apache 2.0" PARENT_SCOPE) SET(NON_DISTRIBUTABLE_WARNING "Apache 2.0" PARENT_SCOPE)
ENDIF() ENDIF()
ADD_FEATURE_INFO(AWS_KEY_MANAGEMENT "ON" "AWS Encryption Key Management Plugin")
...@@ -29,7 +29,7 @@ IF(WIN32) ...@@ -29,7 +29,7 @@ IF(WIN32)
MYSQL_ADD_PLUGIN(authentication_windows_client ${PLUGIN_SOURCES} ${HEADERS} MYSQL_ADD_PLUGIN(authentication_windows_client ${PLUGIN_SOURCES} ${HEADERS}
LINK_LIBRARIES Secur32 LINK_LIBRARIES Secur32
MODULE_ONLY COMPONENT ClientPlugins) MODULE_ONLY COMPONENT ClientPlugins CLIENT)
#IF(MSVC) #IF(MSVC)
# INSTALL_DEBUG_TARGET(auth_win_client DESTINATION ${INSTALL_LIBDIR}/debug) # INSTALL_DEBUG_TARGET(auth_win_client DESTINATION ${INSTALL_LIBDIR}/debug)
......
...@@ -108,6 +108,7 @@ IF(CONNECT_WITH_VCT) ...@@ -108,6 +108,7 @@ IF(CONNECT_WITH_VCT)
SET(CONNECT_SOURCES ${CONNECT_SOURCES} filamvct.cpp tabvct.cpp filamvct.h tabvct.h) SET(CONNECT_SOURCES ${CONNECT_SOURCES} filamvct.cpp tabvct.cpp filamvct.h tabvct.h)
add_definitions(-DVCT_SUPPORT) add_definitions(-DVCT_SUPPORT)
ENDIF(CONNECT_WITH_VCT) ENDIF(CONNECT_WITH_VCT)
ADD_FEATURE_INFO(CONNECT_VCT CONNECT_WITH_VCT "Support for VCT in the CONNECT storage engine")
# #
...@@ -133,6 +134,7 @@ IF(CONNECT_WITH_LIBXML2) ...@@ -133,6 +134,7 @@ IF(CONNECT_WITH_LIBXML2)
D:/libxml/lib) D:/libxml/lib)
ENDIF(WIN32) ENDIF(WIN32)
FIND_PACKAGE(LibXml2) FIND_PACKAGE(LibXml2)
SET_PACKAGE_PROPERTIES(LibXml2 PROPERTIES TYPE OPTIONAL)
IF (LIBXML2_FOUND) IF (LIBXML2_FOUND)
INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR}) INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR})
SET(XML_LIBRARY ${LIBXML2_LIBRARIES}) SET(XML_LIBRARY ${LIBXML2_LIBRARIES})
...@@ -140,6 +142,8 @@ IF(CONNECT_WITH_LIBXML2) ...@@ -140,6 +142,8 @@ IF(CONNECT_WITH_LIBXML2)
add_definitions(-DLIBXML2_SUPPORT) add_definitions(-DLIBXML2_SUPPORT)
ENDIF(LIBXML2_FOUND) ENDIF(LIBXML2_FOUND)
ENDIF(CONNECT_WITH_LIBXML2) ENDIF(CONNECT_WITH_LIBXML2)
ADD_FEATURE_INFO(CONNECT_LIBXML2 CONNECT_WITH_LIBXML2
"Support for LIBXML2 in the CONNECT storage engine")
IF(WIN32) IF(WIN32)
...@@ -153,6 +157,8 @@ IF(WIN32) ...@@ -153,6 +157,8 @@ IF(WIN32)
SET(MSXML_FOUND 1) SET(MSXML_FOUND 1)
SET(CONNECT_SOURCES ${CONNECT_SOURCES} domdoc.cpp domdoc.h) SET(CONNECT_SOURCES ${CONNECT_SOURCES} domdoc.cpp domdoc.h)
ENDIF(CONNECT_WITH_MSXML) ENDIF(CONNECT_WITH_MSXML)
ADD_FEATURE_INFO(CONNECT_MSXML CONNECT_WITH_MSXML
"Support for MSXML in the CONNECT storage engine")
ENDIF(WIN32) ENDIF(WIN32)
IF(LIBXML2_FOUND OR MSXML_FOUND) IF(LIBXML2_FOUND OR MSXML_FOUND)
...@@ -253,6 +259,7 @@ int main() { ...@@ -253,6 +259,7 @@ int main() {
tabodbc.cpp tabodbc.h odbccat.h odbconn.cpp odbconn.h) tabodbc.cpp tabodbc.h odbccat.h odbconn.cpp odbconn.h)
ENDIF(UNIX) ENDIF(UNIX)
ENDIF(CONNECT_WITH_ODBC) ENDIF(CONNECT_WITH_ODBC)
ADD_FEATURE_INFO(CONNECT_ODBC ODBC_LIBRARY "Support for ODBC in the CONNECT storage engine")
# #
# JDBC with MongoDB Java Driver included but disabled if without MONGO # JDBC with MongoDB Java Driver included but disabled if without MONGO
...@@ -262,7 +269,9 @@ OPTION(CONNECT_WITH_JDBC "Compile CONNECT storage engine with JDBC support" ON) ...@@ -262,7 +269,9 @@ OPTION(CONNECT_WITH_JDBC "Compile CONNECT storage engine with JDBC support" ON)
IF(CONNECT_WITH_JDBC) IF(CONNECT_WITH_JDBC)
FIND_PACKAGE(Java 1.6) FIND_PACKAGE(Java 1.6)
SET_PACKAGE_PROPERTIES(Java PROPERTIES TYPE OPTIONAL)
FIND_PACKAGE(JNI) FIND_PACKAGE(JNI)
SET_PACKAGE_PROPERTIES(JNI PROPERTIES TYPE OPTIONAL)
IF (JAVA_FOUND AND JNI_FOUND) IF (JAVA_FOUND AND JNI_FOUND)
INCLUDE(UseJava) INCLUDE(UseJava)
INCLUDE_DIRECTORIES(${JAVA_INCLUDE_PATH}) INCLUDE_DIRECTORIES(${JAVA_INCLUDE_PATH})
...@@ -278,6 +287,7 @@ IF(CONNECT_WITH_JDBC) ...@@ -278,6 +287,7 @@ IF(CONNECT_WITH_JDBC)
Mongo2Interface.java Mongo3Interface.java Mongo2Interface.java Mongo3Interface.java
mysql-test/connect/std_data/JavaWrappers.jar) mysql-test/connect/std_data/JavaWrappers.jar)
add_definitions(-DJAVA_SUPPORT) add_definitions(-DJAVA_SUPPORT)
ADD_FEATURE_INFO(CONNECT_JDBC "ON" "Support for JDBC in the CONNECT storage engine")
IF(CONNECT_WITH_MONGO) IF(CONNECT_WITH_MONGO)
SET(CONNECT_SOURCES ${CONNECT_SOURCES} SET(CONNECT_SOURCES ${CONNECT_SOURCES}
mysql-test/connect/std_data/Mongo2.jar mysql-test/connect/std_data/Mongo2.jar
...@@ -286,7 +296,10 @@ IF(CONNECT_WITH_JDBC) ...@@ -286,7 +296,10 @@ IF(CONNECT_WITH_JDBC)
ENDIF() ENDIF()
ELSE() ELSE()
SET(JDBC_LIBRARY "") SET(JDBC_LIBRARY "")
ADD_FEATURE_INFO(CONNECT_JDBC "OFF" "Support for JDBC in the CONNECT storage engine")
ENDIF() ENDIF()
ELSE(CONNECT_WITH_JDBC)
ADD_FEATURE_INFO(CONNECT_JDBC "OFF" "Support for JDBC in the CONNECT storage engine")
ENDIF(CONNECT_WITH_JDBC) ENDIF(CONNECT_WITH_JDBC)
# #
...@@ -300,6 +313,7 @@ IF(CONNECT_WITH_ZIP) ...@@ -300,6 +313,7 @@ IF(CONNECT_WITH_ZIP)
filamzip.h tabzip.h ioapi.h unzip.h zip.h) filamzip.h tabzip.h ioapi.h unzip.h zip.h)
add_definitions(-DZIP_SUPPORT -DNOCRYPT) add_definitions(-DZIP_SUPPORT -DNOCRYPT)
ENDIF(CONNECT_WITH_ZIP) ENDIF(CONNECT_WITH_ZIP)
ADD_FEATURE_INFO(CONNECT_ZIP CONNECT_WITH_ZIP "Support for ZIP in the CONNECT storage engine")
# #
# MONGO C Driver # MONGO C Driver
...@@ -316,6 +330,7 @@ IF(CONNECT_WITH_MONGO) ...@@ -316,6 +330,7 @@ IF(CONNECT_WITH_MONGO)
D:/mongo-c-driver/lib) D:/mongo-c-driver/lib)
ENDIF(WIN32) ENDIF(WIN32)
FIND_PACKAGE(libmongoc-1.0 1.7 QUIET) FIND_PACKAGE(libmongoc-1.0 1.7 QUIET)
SET_PACKAGE_PROPERTIES(libmongoc PROPERTIES TYPE OPTIONAL)
IF (libmongoc-1.0_FOUND) IF (libmongoc-1.0_FOUND)
INCLUDE_DIRECTORIES(${MONGOC_INCLUDE_DIRS}) INCLUDE_DIRECTORIES(${MONGOC_INCLUDE_DIRS})
SET(MONGOC_LIBRARY ${MONGOC_LIBRARIES}) SET(MONGOC_LIBRARY ${MONGOC_LIBRARIES})
...@@ -323,14 +338,18 @@ IF(CONNECT_WITH_MONGO) ...@@ -323,14 +338,18 @@ IF(CONNECT_WITH_MONGO)
cmgoconn.cpp cmgfam.cpp tabcmg.cpp cmgoconn.cpp cmgfam.cpp tabcmg.cpp
cmgoconn.h cmgfam.h tabcmg.h) cmgoconn.h cmgfam.h tabcmg.h)
add_definitions(-DCMGO_SUPPORT) add_definitions(-DCMGO_SUPPORT)
ADD_FEATURE_INFO(CONNECT_MONGODB "ON" "Support for MongoDB in the CONNECT storage engine")
IF (NOT JAVA_FOUND AND JNI_FOUND) IF (NOT JAVA_FOUND AND JNI_FOUND)
SET(CONNECT_SOURCES ${CONNECT_SOURCES} mongo.cpp mongo.h) SET(CONNECT_SOURCES ${CONNECT_SOURCES} mongo.cpp mongo.h)
add_definitions(-DMONGO_SUPPORT) add_definitions(-DMONGO_SUPPORT)
ENDIF (NOT JAVA_FOUND AND JNI_FOUND) ENDIF (NOT JAVA_FOUND AND JNI_FOUND)
ELSE(libmongoc-1.0_FOUND)
ADD_FEATURE_INFO(CONNECT_MONGODB "OFF" "Support for MongoDB in the CONNECT storage engine")
ENDIF(libmongoc-1.0_FOUND) ENDIF(libmongoc-1.0_FOUND)
ELSE(CONNECT_WITH_MONGO)
ADD_FEATURE_INFO(CONNECT_MONGODB "OFF" "Support for MongoDB in the CONNECT storage engine")
ENDIF(CONNECT_WITH_MONGO) ENDIF(CONNECT_WITH_MONGO)
# #
# REST # REST
# #
...@@ -362,6 +381,7 @@ IF(CONNECT_WITH_REST) ...@@ -362,6 +381,7 @@ IF(CONNECT_WITH_REST)
## MESSAGE(STATUS "=====> cpprestsdk package not found") ## MESSAGE(STATUS "=====> cpprestsdk package not found")
# ENDIF (cpprestsdk_FOUND) # ENDIF (cpprestsdk_FOUND)
ENDIF(CONNECT_WITH_REST) ENDIF(CONNECT_WITH_REST)
ADD_FEATURE_INFO(CONNECT_REST CONNECT_WITH_REST "Support for REST API in the CONNECT storage engine")
# #
# XMAP # XMAP
...@@ -372,6 +392,7 @@ OPTION(CONNECT_WITH_XMAP "Compile CONNECT storage engine with index file mapping ...@@ -372,6 +392,7 @@ OPTION(CONNECT_WITH_XMAP "Compile CONNECT storage engine with index file mapping
IF(CONNECT_WITH_XMAP) IF(CONNECT_WITH_XMAP)
add_definitions(-DXMAP) add_definitions(-DXMAP)
ENDIF(CONNECT_WITH_XMAP) ENDIF(CONNECT_WITH_XMAP)
ADD_FEATURE_INFO(CONNECT_XMAP CONNECT_WITH_XMAP "Support for index file mapping in the CONNECT storage engine")
# #
# Plugin definition # Plugin definition
......
...@@ -22,12 +22,15 @@ MACRO (MYSQL_CHECK_BZIP2) ...@@ -22,12 +22,15 @@ MACRO (MYSQL_CHECK_BZIP2)
CHECK_LIBRARY_EXISTS(bz2 BZ2_bzBuffToBuffDecompress "" HAVE_BZLIB2_DECOMPRESS) CHECK_LIBRARY_EXISTS(bz2 BZ2_bzBuffToBuffDecompress "" HAVE_BZLIB2_DECOMPRESS)
IF (HAVE_BZLIB2_COMPRESS AND HAVE_BZLIB2_DECOMPRESS AND HAVE_BZLIB2_H) IF (HAVE_BZLIB2_COMPRESS AND HAVE_BZLIB2_DECOMPRESS AND HAVE_BZLIB2_H)
SET(HAVE_INNODB_BZLIB2 TRUE)
ADD_DEFINITIONS(-DHAVE_BZIP2=1) ADD_DEFINITIONS(-DHAVE_BZIP2=1)
LINK_LIBRARIES(bz2) LINK_LIBRARIES(bz2)
ELSE() ELSE()
IF (WITH_INNODB_BZIP2 STREQUAL "ON") IF (WITH_INNODB_BZIP2 STREQUAL "ON")
MESSAGE(FATAL_ERROR "Required bzip2 library is not found") MESSAGE(FATAL_ERROR "Required bzip2 library is not found")
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_BZIP2 HAVE_INNODB_BZLIB2
"BZIP2 compression in the InnoDB storage engine")
ENDMACRO() ENDMACRO()
...@@ -86,6 +86,7 @@ MARK_AS_ADVANCED(INNODB_COMPILER_HINTS) ...@@ -86,6 +86,7 @@ MARK_AS_ADVANCED(INNODB_COMPILER_HINTS)
IF(INNODB_COMPILER_HINTS) IF(INNODB_COMPILER_HINTS)
ADD_DEFINITIONS("-DCOMPILER_HINTS") ADD_DEFINITIONS("-DCOMPILER_HINTS")
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_COMPILER_HINTS INNODB_COMPILER_HINTS "InnoDB compiled with compiler hints")
SET(MUTEXTYPE "event" CACHE STRING "Mutex type: event, sys or futex") SET(MUTEXTYPE "event" CACHE STRING "Mutex type: event, sys or futex")
...@@ -121,15 +122,20 @@ IF(WITH_INNODB_AHI) ...@@ -121,15 +122,20 @@ IF(WITH_INNODB_AHI)
ADD_DEFINITIONS(-DBTR_CUR_HASH_ADAPT -DBTR_CUR_ADAPT) ADD_DEFINITIONS(-DBTR_CUR_HASH_ADAPT -DBTR_CUR_ADAPT)
IF(NOT WITH_INNODB_ROOT_GUESS) IF(NOT WITH_INNODB_ROOT_GUESS)
MESSAGE(WARNING "WITH_INNODB_AHI implies WITH_INNODB_ROOT_GUESS") MESSAGE(WARNING "WITH_INNODB_AHI implies WITH_INNODB_ROOT_GUESS")
SET(WITH_INNODB_ROOT_GUESS ON)
ENDIF() ENDIF()
ELSEIF(WITH_INNODB_ROOT_GUESS) ELSEIF(WITH_INNODB_ROOT_GUESS)
ADD_DEFINITIONS(-DBTR_CUR_ADAPT) ADD_DEFINITIONS(-DBTR_CUR_ADAPT)
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_AHI WITH_INNODB_AHI "InnoDB Adaptive Hash Index")
ADD_FEATURE_INFO(INNODB_ROOT_GUESS WITH_INNODB_ROOT_GUESS
"Cache index root block descriptors in InnoDB")
OPTION(WITH_INNODB_BUG_ENDIAN_CRC32 "Weaken innodb_checksum_algorithm=crc32 by supporting upgrade from big-endian systems running 5.6/10.0/10.1" ${IS_BIG_ENDIAN}) OPTION(WITH_INNODB_BUG_ENDIAN_CRC32 "Weaken innodb_checksum_algorithm=crc32 by supporting upgrade from big-endian systems running 5.6/10.0/10.1" ${IS_BIG_ENDIAN})
IF(WITH_INNODB_BUG_ENDIAN_CRC32) IF(WITH_INNODB_BUG_ENDIAN_CRC32)
ADD_DEFINITIONS(-DINNODB_BUG_ENDIAN_CRC32) ADD_DEFINITIONS(-DINNODB_BUG_ENDIAN_CRC32)
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_BUG_ENDIAN_CRC32 WITH_INNODB_BUG_ENDIAN_CRC32 "Big endian weaker CRC32 to support upgrade from big-endian systems running 5.6/10.0/10.1")
OPTION(WITH_INNODB_EXTRA_DEBUG "Enable extra InnoDB debug checks" OFF) OPTION(WITH_INNODB_EXTRA_DEBUG "Enable extra InnoDB debug checks" OFF)
IF(WITH_INNODB_EXTRA_DEBUG) IF(WITH_INNODB_EXTRA_DEBUG)
...@@ -148,6 +154,8 @@ IF(WITH_INNODB_EXTRA_DEBUG) ...@@ -148,6 +154,8 @@ IF(WITH_INNODB_EXTRA_DEBUG)
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${EXTRA_DEBUG_FLAGS}") SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${EXTRA_DEBUG_FLAGS}")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} ${EXTRA_DEBUG_FLAGS}") SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} ${EXTRA_DEBUG_FLAGS}")
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_EXTRA_DEBUG WITH_INNODB_EXTRA_DEBUG "Extra InnoDB debug checks")
CHECK_FUNCTION_EXISTS(sched_getcpu HAVE_SCHED_GETCPU) CHECK_FUNCTION_EXISTS(sched_getcpu HAVE_SCHED_GETCPU)
IF(HAVE_SCHED_GETCPU) IF(HAVE_SCHED_GETCPU)
...@@ -239,6 +247,7 @@ OPTION(WITH_INNODB_DISALLOW_WRITES "InnoDB freeze writes patch from Google" ${WI ...@@ -239,6 +247,7 @@ OPTION(WITH_INNODB_DISALLOW_WRITES "InnoDB freeze writes patch from Google" ${WI
IF (WITH_INNODB_DISALLOW_WRITES) IF (WITH_INNODB_DISALLOW_WRITES)
ADD_DEFINITIONS(-DWITH_INNODB_DISALLOW_WRITES) ADD_DEFINITIONS(-DWITH_INNODB_DISALLOW_WRITES)
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_DISALLOW_WRITES WITH_INNODB_DISALLOW_WRITES "Expose innodb_disallow_writes switch to stop innodb from writing to disk")
# Include directories under innobase # Include directories under innobase
...@@ -281,8 +290,8 @@ IF(MSVC) ...@@ -281,8 +290,8 @@ IF(MSVC)
SET_SOURCE_FILES_PROPERTIES(${_SRC_DIR}/pars/lexyy.c SET_SOURCE_FILES_PROPERTIES(${_SRC_DIR}/pars/lexyy.c
PROPERTIES COMPILE_FLAGS "/wd4003") PROPERTIES COMPILE_FLAGS "/wd4003")
ENDIF() ENDIF()
# Include directories under innobase # Include directories under innobase
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/storage/innobase/include INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/storage/innobase/include
${CMAKE_SOURCE_DIR}/storage/innobase/handler ${CMAKE_SOURCE_DIR}/storage/innobase/handler
${CMAKE_SOURCE_DIR}/libbinlogevents/include ) ${CMAKE_SOURCE_DIR}/libbinlogevents/include )
...@@ -22,15 +22,17 @@ MACRO (MYSQL_CHECK_LZ4) ...@@ -22,15 +22,17 @@ MACRO (MYSQL_CHECK_LZ4)
CHECK_LIBRARY_EXISTS(lz4 LZ4_compress_default "" HAVE_LZ4_COMPRESS_DEFAULT) CHECK_LIBRARY_EXISTS(lz4 LZ4_compress_default "" HAVE_LZ4_COMPRESS_DEFAULT)
IF (HAVE_LZ4_SHARED_LIB AND HAVE_LZ4_H) IF (HAVE_LZ4_SHARED_LIB AND HAVE_LZ4_H)
SET(HAVE_INNODB_LZ4 TRUE)
ADD_DEFINITIONS(-DHAVE_LZ4=1) ADD_DEFINITIONS(-DHAVE_LZ4=1)
IF (HAVE_LZ4_COMPRESS_DEFAULT) IF (HAVE_LZ4_COMPRESS_DEFAULT)
ADD_DEFINITIONS(-DHAVE_LZ4_COMPRESS_DEFAULT=1) ADD_DEFINITIONS(-DHAVE_LZ4_COMPRESS_DEFAULT=1)
ENDIF() ENDIF()
LINK_LIBRARIES(lz4) LINK_LIBRARIES(lz4)
ELSE() ELSE()
IF (WITH_INNODB_LZ4 STREQUAL "ON") IF (WITH_INNODB_LZ4 STREQUAL "ON")
MESSAGE(FATAL_ERROR "Required lz4 library is not found") MESSAGE(FATAL_ERROR "Required lz4 library is not found")
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_LZ4 HAVE_INNODB_LZ4 "LZ4 compression in the InnoDB storage engine")
ENDMACRO() ENDMACRO()
...@@ -22,12 +22,14 @@ MACRO (MYSQL_CHECK_LZMA) ...@@ -22,12 +22,14 @@ MACRO (MYSQL_CHECK_LZMA)
CHECK_LIBRARY_EXISTS(lzma lzma_easy_buffer_encode "" HAVE_LZMA_ENCODE) CHECK_LIBRARY_EXISTS(lzma lzma_easy_buffer_encode "" HAVE_LZMA_ENCODE)
IF (HAVE_LZMA_DECODE AND HAVE_LZMA_ENCODE AND HAVE_LZMA_H) IF (HAVE_LZMA_DECODE AND HAVE_LZMA_ENCODE AND HAVE_LZMA_H)
SET(HAVE_INNODB_LZMA TRUE)
ADD_DEFINITIONS(-DHAVE_LZMA=1) ADD_DEFINITIONS(-DHAVE_LZMA=1)
LINK_LIBRARIES(lzma) LINK_LIBRARIES(lzma)
ELSE() ELSE()
IF (WITH_INNODB_LZMA STREQUAL "ON") IF (WITH_INNODB_LZMA STREQUAL "ON")
MESSAGE(FATAL_ERROR "Required lzma library is not found") MESSAGE(FATAL_ERROR "Required lzma library is not found")
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_LZMA HAVE_INNODB_LZMA "LZMA compression in the InnoDB storage engine")
ENDMACRO() ENDMACRO()
...@@ -21,12 +21,14 @@ MACRO (MYSQL_CHECK_LZO) ...@@ -21,12 +21,14 @@ MACRO (MYSQL_CHECK_LZO)
CHECK_LIBRARY_EXISTS(lzo2 lzo1x_1_compress "" HAVE_LZO_SHARED_LIB) CHECK_LIBRARY_EXISTS(lzo2 lzo1x_1_compress "" HAVE_LZO_SHARED_LIB)
IF(HAVE_LZO_SHARED_LIB AND HAVE_LZO_H) IF(HAVE_LZO_SHARED_LIB AND HAVE_LZO_H)
SET(HAVE_INNODB_LZO TRUE)
ADD_DEFINITIONS(-DHAVE_LZO=1) ADD_DEFINITIONS(-DHAVE_LZO=1)
LINK_LIBRARIES(lzo2) LINK_LIBRARIES(lzo2)
ELSE() ELSE()
IF (WITH_INNODB_LZO STREQUAL "ON") IF (WITH_INNODB_LZO STREQUAL "ON")
MESSAGE(FATAL_ERROR "Required lzo library is not found") MESSAGE(FATAL_ERROR "Required lzo library is not found")
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_LZO HAVE_INNODB_LZO "LZO compression in the InnoDB storage engine")
ENDMACRO() ENDMACRO()
...@@ -21,12 +21,14 @@ MACRO (MYSQL_CHECK_SNAPPY) ...@@ -21,12 +21,14 @@ MACRO (MYSQL_CHECK_SNAPPY)
CHECK_LIBRARY_EXISTS(snappy snappy_uncompress "" HAVE_SNAPPY_SHARED_LIB) CHECK_LIBRARY_EXISTS(snappy snappy_uncompress "" HAVE_SNAPPY_SHARED_LIB)
IF(HAVE_SNAPPY_SHARED_LIB AND HAVE_SNAPPY_H) IF(HAVE_SNAPPY_SHARED_LIB AND HAVE_SNAPPY_H)
SET(HAVE_INNODB_SNAPPY TRUE)
ADD_DEFINITIONS(-DHAVE_SNAPPY=1) ADD_DEFINITIONS(-DHAVE_SNAPPY=1)
LINK_LIBRARIES(snappy) LINK_LIBRARIES(snappy)
ELSE() ELSE()
IF (WITH_INNODB_SNAPPY STREQUAL "ON") IF (WITH_INNODB_SNAPPY STREQUAL "ON")
MESSAGE(FATAL_ERROR "Required snappy library is not found") MESSAGE(FATAL_ERROR "Required snappy library is not found")
ENDIF() ENDIF()
ENDIF() ENDIF()
ENDIF() ENDIF()
ADD_FEATURE_INFO(INNODB_SNAPPY HAVE_INNODB_SNAPPY "Snappy compression in the InnoDB storage engine")
ENDMACRO() ENDMACRO()
...@@ -3,6 +3,10 @@ set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") ...@@ -3,6 +3,10 @@ set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
FUNCTION(CHECK_OQGRAPH) FUNCTION(CHECK_OQGRAPH)
MESSAGE(STATUS "Configuring OQGraph") MESSAGE(STATUS "Configuring OQGraph")
FIND_PACKAGE(Boost 1.40.0) FIND_PACKAGE(Boost 1.40.0)
SET_PACKAGE_PROPERTIES(Boost PROPERTIES
PURPOSE "Required for the OQGraph storage engine"
TYPE OPTIONAL
)
IF(NOT Boost_FOUND) IF(NOT Boost_FOUND)
MESSAGE(STATUS "Boost not found. OQGraph will not be compiled") MESSAGE(STATUS "Boost not found. OQGraph will not be compiled")
SET(OQGRAPH_OK 0 CACHE INTERNAL "") SET(OQGRAPH_OK 0 CACHE INTERNAL "")
...@@ -11,6 +15,10 @@ ENDIF() ...@@ -11,6 +15,10 @@ ENDIF()
INCLUDE_DIRECTORIES(BEFORE ${Boost_INCLUDE_DIRS}) INCLUDE_DIRECTORIES(BEFORE ${Boost_INCLUDE_DIRS})
FIND_PACKAGE(Judy) FIND_PACKAGE(Judy)
SET_PACKAGE_PROPERTIES(Judy PROPERTIES
PURPOSE "Required for the OQGraph storage engine"
TYPE OPTIONAL
)
IF(NOT Judy_FOUND) IF(NOT Judy_FOUND)
MESSAGE(STATUS "Judy not found. OQGraph will not be compiled") MESSAGE(STATUS "Judy not found. OQGraph will not be compiled")
SET(OQGRAPH_OK 0 CACHE INTERNAL "") SET(OQGRAPH_OK 0 CACHE INTERNAL "")
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
MACRO(SKIP_ROCKSDB_PLUGIN msg) MACRO(SKIP_ROCKSDB_PLUGIN msg)
MESSAGE_ONCE(SKIP_ROCKSDB_PLUGIN "Can't build rocksdb engine - ${msg}") MESSAGE_ONCE(SKIP_ROCKSDB_PLUGIN "Can't build rocksdb engine - ${msg}")
ADD_FEATURE_INFO(ROCKSDB "OFF" "Storage Engine")
RETURN() RETURN()
ENDMACRO() ENDMACRO()
......
...@@ -48,22 +48,28 @@ foreach(compression_lib LZ4 BZip2 ZSTD snappy) ...@@ -48,22 +48,28 @@ foreach(compression_lib LZ4 BZip2 ZSTD snappy)
endforeach() endforeach()
if(LZ4_FOUND AND (NOT WITH_ROCKSDB_LZ4 STREQUAL "OFF")) if(LZ4_FOUND AND (NOT WITH_ROCKSDB_LZ4 STREQUAL "OFF"))
set(HAVE_ROCKSDB_LZ4 TRUE)
add_definitions(-DLZ4) add_definitions(-DLZ4)
include_directories(${LZ4_INCLUDE_DIR}) include_directories(${LZ4_INCLUDE_DIR})
list(APPEND THIRDPARTY_LIBS ${LZ4_LIBRARY}) list(APPEND THIRDPARTY_LIBS ${LZ4_LIBRARY})
endif() endif()
ADD_FEATURE_INFO(ROCKSDB_LZ4 HAVE_ROCKSDB_LZ4 "LZ4 Compression in the RocksDB storage engine")
if(BZIP2_FOUND AND (NOT WITH_ROCKSDB_BZip2 STREQUAL "OFF")) if(BZIP2_FOUND AND (NOT WITH_ROCKSDB_BZip2 STREQUAL "OFF"))
set(HAVE_ROCKSDB_BZIP2 TRUE)
add_definitions(-DBZIP2) add_definitions(-DBZIP2)
include_directories(${BZIP2_INCLUDE_DIR}) include_directories(${BZIP2_INCLUDE_DIR})
list(APPEND THIRDPARTY_LIBS ${BZIP2_LIBRARIES}) list(APPEND THIRDPARTY_LIBS ${BZIP2_LIBRARIES})
endif() endif()
ADD_FEATURE_INFO(ROCKSDB_BZIP2 HAVE_ROCKSDB_BZIP2 "BZIP2 Compression in the RocksDB storage engine")
if(SNAPPY_FOUND AND (NOT WITH_ROCKSDB_snappy STREQUAL "OFF")) if(SNAPPY_FOUND AND (NOT WITH_ROCKSDB_snappy STREQUAL "OFF"))
set(HAVE_ROCKSDB_SNAPPY TRUE)
add_definitions(-DSNAPPY) add_definitions(-DSNAPPY)
include_directories(${snappy_INCLUDE_DIR}) include_directories(${snappy_INCLUDE_DIR})
list(APPEND THIRDPARTY_LIBS ${snappy_LIBRARIES}) list(APPEND THIRDPARTY_LIBS ${snappy_LIBRARIES})
endif() endif()
ADD_FEATURE_INFO(ROCKSDB_SNAPPY HAVE_ROCKSDB_SNAPPY "Snappy Compression in the RocksDB storage engine")
include(CheckFunctionExists) include(CheckFunctionExists)
if(ZSTD_FOUND AND (NOT WITH_ROCKSDB_ZSTD STREQUAL "OFF")) if(ZSTD_FOUND AND (NOT WITH_ROCKSDB_ZSTD STREQUAL "OFF"))
...@@ -75,14 +81,17 @@ if(ZSTD_FOUND AND (NOT WITH_ROCKSDB_ZSTD STREQUAL "OFF")) ...@@ -75,14 +81,17 @@ if(ZSTD_FOUND AND (NOT WITH_ROCKSDB_ZSTD STREQUAL "OFF"))
"WITH_ROCKSDB_ZSTD is ON and ZSTD library was found, but the version needs to be >= 1.1.3") "WITH_ROCKSDB_ZSTD is ON and ZSTD library was found, but the version needs to be >= 1.1.3")
endif() endif()
if (ZSTD_VALID) if (ZSTD_VALID)
set(HAVE_ROCKSDB_ZSTD TRUE)
add_definitions(-DZSTD) add_definitions(-DZSTD)
include_directories(${ZSTD_INCLUDE_DIR}) include_directories(${ZSTD_INCLUDE_DIR})
list(APPEND THIRDPARTY_LIBS ${ZSTD_LIBRARY}) list(APPEND THIRDPARTY_LIBS ${ZSTD_LIBRARY})
endif() endif()
endif() endif()
ADD_FEATURE_INFO(ROCKSDB_ZSTD HAVE_ROCKSDB_ZSTD "Zstandard Compression in the RocksDB storage engine")
add_definitions(-DZLIB) add_definitions(-DZLIB)
list(APPEND THIRDPARTY_LIBS ${ZLIB_LIBRARY}) list(APPEND THIRDPARTY_LIBS ${ZLIB_LIBRARY})
ADD_FEATURE_INFO(ROCKSDB_ZLIB "ON" "zlib Compression in the RocksDB storage engine")
if(CMAKE_SYSTEM_NAME MATCHES "Cygwin") if(CMAKE_SYSTEM_NAME MATCHES "Cygwin")
add_definitions(-fno-builtin-memcmp -DCYGWIN) add_definitions(-fno-builtin-memcmp -DCYGWIN)
......
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