summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmake/cpack_rpm.cmake8
-rw-r--r--cmake/install_layout.cmake7
-rw-r--r--debian/mariadb-tokudb-engine-5.5.files1
-rw-r--r--storage/tokudb/CMakeLists.txt6
-rw-r--r--storage/tokudb/tokudb.cnf9
-rw-r--r--support-files/CMakeLists.txt6
6 files changed, 28 insertions, 9 deletions
diff --git a/cmake/cpack_rpm.cmake b/cmake/cpack_rpm.cmake
index ee800fca4e4..c21b863c71f 100644
--- a/cmake/cpack_rpm.cmake
+++ b/cmake/cpack_rpm.cmake
@@ -86,10 +86,10 @@ SET(ignored
"%ignore ${CMAKE_INSTALL_PREFIX}/share/man/man8*"
)
-SET(CPACK_RPM_server_USER_FILELIST ${ignored} "%config(noreplace) /etc/my.cnf.d/*")
-SET(CPACK_RPM_common_USER_FILELIST ${ignored} "%config(noreplace) /etc/my.cnf")
-SET(CPACK_RPM_shared_USER_FILELIST ${ignored} "%config(noreplace) /etc/my.cnf.d/*")
-SET(CPACK_RPM_client_USER_FILELIST ${ignored} "%config(noreplace) /etc/my.cnf.d/*")
+SET(CPACK_RPM_server_USER_FILELIST ${ignored} "%config(noreplace) ${INSTALL_SYSCONF2DIR}/*")
+SET(CPACK_RPM_common_USER_FILELIST ${ignored} "%config(noreplace) ${INSTALL_SYSCONFDIR}/my.cnf")
+SET(CPACK_RPM_shared_USER_FILELIST ${ignored} "%config(noreplace) ${INSTALL_SYSCONF2DIR}/*")
+SET(CPACK_RPM_client_USER_FILELIST ${ignored} "%config(noreplace) ${INSTALL_SYSCONF2DIR}/*")
SET(CPACK_RPM_compat_USER_FILELIST ${ignored})
SET(CPACK_RPM_devel_USER_FILELIST ${ignored})
SET(CPACK_RPM_test_USER_FILELIST ${ignored})
diff --git a/cmake/install_layout.cmake b/cmake/install_layout.cmake
index be9f32fb94a..d5f60832884 100644
--- a/cmake/install_layout.cmake
+++ b/cmake/install_layout.cmake
@@ -41,7 +41,8 @@
# - INSTALL_BINDIR (directory with client executables and scripts)
# - INSTALL_SBINDIR (directory with mysqld)
# - INSTALL_SCRIPTDIR (several scripts, rarely used)
-# - INSTALL_SYSCONFDIR (config files. Usually /etc or nothing)
+# - INSTALL_SYSCONFDIR (my.cnf config file. Usually /etc or nothing)
+# - INSTALL_SYSCONF2DIR (additional config files, e.g. /etc/mysql/conf.d)
#
# - INSTALL_LIBDIR (directory with client end embedded libraries)
# - INSTALL_PLUGINDIR (directory for plugins)
@@ -145,6 +146,7 @@ SET(INSTALL_BINDIR_RPM "bin")
SET(INSTALL_SBINDIR_RPM "sbin")
SET(INSTALL_SCRIPTDIR_RPM "bin")
SET(INSTALL_SYSCONFDIR_RPM "/etc")
+SET(INSTALL_SYSCONF2DIR_RPM "/etc/my.cnf.d")
#
IF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
SET(INSTALL_LIBDIR_RPM "lib64")
@@ -178,6 +180,7 @@ SET(INSTALL_UNIX_ADDRDIR_RPM "${INSTALL_MYSQLDATADIR_RPM}/mysql.sock"
SET(INSTALL_BINDIR_DEB "bin")
SET(INSTALL_SBINDIR_DEB "sbin")
SET(INSTALL_SCRIPTDIR_DEB "bin")
+SET(INSTALL_SYSCONF2DIR_DEB "/etc/mysql/conf.d")
#
SET(INSTALL_LIBDIR_DEB "lib")
SET(INSTALL_PLUGINDIR_DEB "lib/mysql/plugin")
@@ -238,7 +241,7 @@ SET(OLD_INSTALL_LAYOUT ${INSTALL_LAYOUT} CACHE INTERNAL "")
# Set INSTALL_FOODIR variables for chosen layout (for example, INSTALL_BINDIR
# will be defined as ${INSTALL_BINDIR_STANDALONE} by default if STANDALONE
# layout is chosen)
-FOREACH(var BIN SBIN LIB MYSQLSHARE SHARE PLUGIN INCLUDE SCRIPT DOC MAN SYSCONF
+FOREACH(var BIN SBIN LIB MYSQLSHARE SHARE PLUGIN INCLUDE SCRIPT DOC MAN SYSCONF SYSCONF2
INFO MYSQLTEST SQLBENCH DOCREADME SUPPORTFILES MYSQLDATA PLUGINTEST UNIX_ADDR)
SET(INSTALL_${var}DIR ${INSTALL_${var}DIR_${INSTALL_LAYOUT}}
CACHE STRING "${var} installation directory" ${FORCE})
diff --git a/debian/mariadb-tokudb-engine-5.5.files b/debian/mariadb-tokudb-engine-5.5.files
index e2033f1acbf..2dc9f22d77a 100644
--- a/debian/mariadb-tokudb-engine-5.5.files
+++ b/debian/mariadb-tokudb-engine-5.5.files
@@ -1,3 +1,4 @@
+etc/mysql/conf.d/tokudb.cnf
usr/bin/tokuftdump
usr/lib/mysql/plugin/ha_tokudb.so
usr/share/doc/mariadb-tokudb-engine-5.5/README-TOKUDB
diff --git a/storage/tokudb/CMakeLists.txt b/storage/tokudb/CMakeLists.txt
index f6776d02602..28c714fb7d9 100644
--- a/storage/tokudb/CMakeLists.txt
+++ b/storage/tokudb/CMakeLists.txt
@@ -47,3 +47,9 @@ MYSQL_ADD_PLUGIN(tokudb ${TOKUDB_SOURCES} STORAGE_ENGINE MODULE_ONLY
COMPONENT "tokudb-engine"
LINK_LIBRARIES tokufractaltree_static tokuportability_static z stdc++)
SET(CMAKE_MODULE_LINKER_FLAGS_RELEASE "${CMAKE_MODULE_LINKER_FLAGS_RELEASE} -flto -fuse-linker-plugin")
+
+IF (INSTALL_SYSCONF2DIR)
+ INSTALL(FILES tokudb.cnf DESTINATION ${INSTALL_SYSCONF2DIR} COMPONENT tokudb-engine)
+ SET(CPACK_RPM_tokudb-engine_USER_FILELIST ${ignored} "%config(noreplace) ${INSTALL_SYSCONF2DIR}/*" PARENT_SCOPE)
+ENDIF(INSTALL_SYSCONF2DIR)
+
diff --git a/storage/tokudb/tokudb.cnf b/storage/tokudb/tokudb.cnf
new file mode 100644
index 00000000000..84f98e6d9b9
--- /dev/null
+++ b/storage/tokudb/tokudb.cnf
@@ -0,0 +1,9 @@
+[mariadb]
+# See https://mariadb.com/kb/en/how-to-enable-tokudb-in-mariadb/
+# for instructions how to enable TokuDB
+#
+# See https://mariadb.com/kb/en/tokudb-differences/ for differences
+# between TokuDB in MariaDB and TokuDB from http://www.tokutek.com/
+
+#plugin-load=ha_tokudb.so
+
diff --git a/support-files/CMakeLists.txt b/support-files/CMakeLists.txt
index fde4746df16..1909c1760d9 100644
--- a/support-files/CMakeLists.txt
+++ b/support-files/CMakeLists.txt
@@ -105,11 +105,11 @@ IF(UNIX)
INSTALL(FILES rpm/my.cnf DESTINATION ${INSTALL_SYSCONFDIR}
COMPONENT Common)
- INSTALL(FILES rpm/client.cnf DESTINATION ${INSTALL_SYSCONFDIR}/my.cnf.d
+ INSTALL(FILES rpm/client.cnf DESTINATION ${INSTALL_SYSCONF2DIR}
COMPONENT SharedLibraries)
- INSTALL(FILES rpm/mysql-clients.cnf DESTINATION ${INSTALL_SYSCONFDIR}/my.cnf.d
+ INSTALL(FILES rpm/mysql-clients.cnf DESTINATION ${INSTALL_SYSCONF2DIR}
COMPONENT Client)
- INSTALL(FILES rpm/server.cnf DESTINATION ${INSTALL_SYSCONFDIR}/my.cnf.d
+ INSTALL(FILES rpm/server.cnf DESTINATION ${INSTALL_SYSCONF2DIR}
COMPONENT IniFiles)
# This is for SuSE: