Bump to 10.2.x release series which has support for OpenSSL 1.1.x.
- libmariadbclient was replaced by libmaria
- libmaria uses LGPL, hence license info updated
- upstream disabled xtradb engine, innodb is now default (cannot be
built as plugin anymore)
- complex charsets are now all included (size increase), as otherwise
compile fails
- patches adapted/refreshed
Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
include $(TOPDIR)/rules.mk
PKG_NAME:=mariadb
-PKG_VERSION:=10.1.33
+PKG_VERSION:=10.2.16
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
https://ftp.yz.yamagata-u.ac.jp/pub/dbms/mariadb/$(PKG_NAME)-$(PKG_VERSION)/source \
https://downloads.mariadb.org/interstitial/$(PKG_NAME)-$(PKG_VERSION)/source
-PKG_HASH:=94312c519f2c0c25e1964c64e22aff0036fb22dfb2685638f43a6b2211395d2d
+PKG_HASH:=c182ee93bacee9c1395a4cece56acfc433bc5153ec627c4898927b93eee54dc4
PKG_MAINTAINER:=Sebastian Kemper <sebastian_ml@gmx.net>
-PKG_LICENSE:=GPL-2.0
-PKG_LICENSE_FILES:=COPYING
+PKG_LICENSE:=GPL-2.0 LGPL-2.1
+PKG_LICENSE_FILES:=COPYING libmariadb/COPYING.LIB
HOST_BUILD_PARALLEL:=1
PKG_BUILD_PARALLEL:=1
ha_example \
ha_federated \
ha_federatedx \
- ha_innodb \
ha_spider \
ha_test_sql_discovery \
handlersocket \
plugin-ha_example := PLUGIN_EXAMPLE
plugin-ha_federated := PLUGIN_FEDERATED
plugin-ha_federatedx := PLUGIN_FEDERATEDX
-plugin-ha_innodb := PLUGIN_INNOBASE
plugin-ha_spider := PLUGIN_SPIDER
plugin-ha_test_sql_discovery := PLUGIN_TEST_SQL_DISCOVERY
plugin-handlersocket := PLUGIN_HANDLERSOCKET
speed, robustness and ease of use.
endef
-define Package/libmariadbclient
+define Package/libmariadb
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=$(MARIADB_COMMON_DEPENDS)
TITLE:=MariaDB database client library
URL:=https://mariadb.org/
- PROVIDES:=libmysqlclient libmysqlclient-r
+ PROVIDES:=libmariadbclient libmysqlclient libmysqlclient-r
endef
-define Package/libmariadbclient/description
+define Package/libmariadb/description
$(call Package/mariadb/description/Default)
This package includes the client library.
define Package/mariadb-extra-charsets/description
$(call Package/mariadb/description/Default)
-The MariaDB server packaged by OpenWrt only provides support for UTF-8.
This package contains single Byte character sets and collations that can
be added at run time.
-DSKIP_TESTS=ON \
-DWITH_ASAN=OFF \
-DWITH_EMBEDDED_SERVER=OFF \
- -DWITH_EXTRA_CHARSETS=none \
+ -DWITH_EXTRA_CHARSETS=complex \
-DWITH_INNODB_BZIP2=OFF \
-DWITH_INNODB_LZ4=OFF \
-DWITH_INNODB_LZMA=ON \
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mysql_config $(1)/usr/bin
$(LN) $(STAGING_DIR)/usr/bin/mysql_config $(2)/bin
$(CP) $(PKG_INSTALL_DIR)/usr/include/mysql $(1)/usr/include
- $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmysqlclient*.so* $(1)/usr/lib
- cd $(1)/usr/lib/mysql; $(LN) ../libmysqlclient*.so* .
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{mariadb,mysqlclient}*.so* $(1)/usr/lib
+ cd $(1)/usr/lib/mysql; $(LN) ../lib{mariadb,mysqlclient}*.so* .
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/pkgconfig/mariadb.pc $(1)/usr/lib/pkgconfig
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/aclocal/mysql.m4 $(1)/usr/share/aclocal
endef
-define Package/libmariadbclient/install
+define Package/libmariadb/install
$(INSTALL_DIR) $(1)$(PLUGIN_DIR)
- $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmysqlclient*.so* $(1)/usr/lib
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{mariadb,mysqlclient}*.so* $(1)/usr/lib
$(INSTALL_BIN) $(PKG_INSTALL_DIR)$(PLUGIN_DIR)/dialog.so $(1)$(PLUGIN_DIR)
$(INSTALL_BIN) $(PKG_INSTALL_DIR)$(PLUGIN_DIR)/mysql_clear_password.so $(1)$(PLUGIN_DIR)
endef
define Package/mariadb-server/conffiles
/etc/mysql/my.cnf
-/usr/lib/mysql/plugin/daemon_example.ini
+$(PLUGIN_DIR)/daemon_example.ini
endef
define BuildPlugin
endef
$(eval $(call HostBuild))
-$(eval $(call BuildPackage,libmariadbclient))
+$(eval $(call BuildPackage,libmariadb))
$(eval $(call BuildPackage,mariadb-client))
$(eval $(call BuildPackage,mariadb-client-extra))
$(eval $(call BuildPackage,mariadb-extra-charsets))
$(eval $(call BuildPlugin,ha_connect,+libxml2))
$(eval $(call BuildPlugin,ha_federated,))
$(eval $(call BuildPlugin,ha_federatedx,))
-$(eval $(call BuildPlugin,ha_innodb,))
$(eval $(call BuildPlugin,ha_spider,))
$(eval $(call BuildPlugin,ha_test_sql_discovery,))
$(eval $(call BuildPlugin,handlersocket,))
--- a/scripts/mysql_install_db.sh
+++ b/scripts/mysql_install_db.sh
-@@ -379,7 +379,7 @@ fi
+@@ -383,7 +383,7 @@ fi
# Try to determine the hostname
--- a/configure.cmake
+++ b/configure.cmake
-@@ -1107,9 +1107,12 @@ SET(CMAKE_EXTRA_INCLUDE_FILES)
- CHECK_STRUCT_HAS_MEMBER("struct dirent" d_ino "dirent.h" STRUCT_DIRENT_HAS_D_INO)
- CHECK_STRUCT_HAS_MEMBER("struct dirent" d_namlen "dirent.h" STRUCT_DIRENT_HAS_D_NAMLEN)
- SET(SPRINTF_RETURNS_INT 1)
+@@ -1018,9 +1018,12 @@ CHECK_STRUCT_HAS_MEMBER("struct sockaddr
+
+ SET(CMAKE_EXTRA_INCLUDE_FILES)
+
-CHECK_INCLUDE_FILE(ucontext.h HAVE_UCONTEXT_H)
-IF(NOT HAVE_UCONTEXT_H)
- CHECK_INCLUDE_FILE(sys/ucontext.h HAVE_UCONTEXT_H)
${LIBM} ${LIBNSL} ${LIBBIND} ${LIBCRYPT} ${LIBSOCKET} ${LIBDL} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT} ${LIBEXECINFO})
# Need explicit pthread for gcc -fsanitize=address
IF(CMAKE_USE_PTHREADS_INIT AND CMAKE_C_FLAGS MATCHES "-fsanitize=")
-@@ -1038,7 +1038,26 @@ ELSEIF(NOT WITH_ATOMIC_OPS)
+@@ -952,7 +952,26 @@ ELSEIF(NOT WITH_ATOMIC_OPS)
long long int *ptr= &var;
return (int)__atomic_load_n(ptr, __ATOMIC_SEQ_CST);
}"
#ifdef MY_ATOMIC_MODE_DUMMY
#define make_atomic_load_body(S) ret= *a
#define make_atomic_store_body(S) *a= v
---- a/include/atomic/nolock.h
-+++ b/include/atomic/nolock.h
-@@ -17,7 +17,7 @@
- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
-
- #if defined(__i386__) || defined(_MSC_VER) || defined(__x86_64__) \
-- || defined(HAVE_GCC_ATOMIC_BUILTINS) \
-+ || defined(HAVE_GCC_ATOMIC_BUILTINS) || defined(HAVE_GCC_C11_ATOMICS) \
- || defined(HAVE_SOLARIS_ATOMIC)
-
- # ifdef MY_ATOMIC_MODE_DUMMY
-@@ -41,7 +41,7 @@
- # elif __GNUC__
- # if defined(HAVE_SOLARIS_ATOMIC)
- # include "solaris.h"
--# elif defined(HAVE_GCC_ATOMIC_BUILTINS)
-+# elif defined(HAVE_GCC_ATOMIC_BUILTINS) || defined(HAVE_GCC_C11_ATOMICS)
- # include "gcc_builtins.h"
- # elif defined(__i386__) || defined(__x86_64__)
- # include "x86-gcc.h"
--- a/mysys/CMakeLists.txt
+++ b/mysys/CMakeLists.txt
-@@ -78,6 +78,10 @@ IF(HAVE_BFD_H)
+@@ -80,6 +80,10 @@ IF(HAVE_BFD_H)
TARGET_LINK_LIBRARIES(mysys bfd)
ENDIF(HAVE_BFD_H)
ENDIF(WIN32)
--- a/sql/CMakeLists.txt
+++ b/sql/CMakeLists.txt
-@@ -165,6 +165,10 @@ TARGET_LINK_LIBRARIES(sql ${MYSQLD_STATI
+@@ -170,6 +170,10 @@ TARGET_LINK_LIBRARIES(sql ${MYSQLD_STATI
${SSL_LIBRARIES}
${LIBSYSTEMD})
IF(WIN32)
SET(MYSQLD_SOURCE main.cc nt_servc.cc message.rc)
TARGET_LINK_LIBRARIES(sql psapi)
+--- a/include/my_atomic.h
++++ b/include/my_atomic.h
+@@ -126,7 +126,7 @@
+ #include "atomic/generic-msvc.h"
+ #elif defined(HAVE_SOLARIS_ATOMIC)
+ #include "atomic/solaris.h"
+-#elif defined(HAVE_GCC_ATOMIC_BUILTINS)
++#elif defined(HAVE_GCC_ATOMIC_BUILTINS) || defined(HAVE_GCC_C11_ATOMICS)
+ #include "atomic/gcc_builtins.h"
+ #elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__))
+ #include "atomic/x86-gcc.h"
+++ /dev/null
-Author: James Cowgill <jcowgill@debian.org>
-Description: fix FTBFS on 32-bit mips*
-Bug-Debian: #864298
-
---- a/storage/innobase/include/os0sync.h
-+++ b/storage/innobase/include/os0sync.h
-@@ -37,6 +37,7 @@ Created 9/6/1995 Heikki Tuuri
-
- #include "univ.i"
- #include "ut0lst.h"
-+#include "sync0types.h"
-
- /** CPU cache line size */
- #ifdef __powerpc__
--- a/storage/xtradb/include/ut0ut.h
+++ b/storage/xtradb/include/ut0ut.h
-@@ -86,8 +86,7 @@ private:
+@@ -85,9 +85,8 @@ private:
+ the YieldProcessor macro defined in WinNT.h. It is a CPU architecture-
independent way by using YieldProcessor. */
# define UT_RELAX_CPU() YieldProcessor()
- # elif defined(__powerpc__)
+-# elif defined(__powerpc__) && defined __GLIBC__
-#include <sys/platform/ppc.h>
-# define UT_RELAX_CPU() __ppc_get_timebase()
++# elif defined(__powerpc__)
+# define UT_RELAX_CPU() __builtin_ppc_get_timebase()
# else
# define UT_RELAX_CPU() ((void)0) /* avoid warning for an empty statement */
# define UT_RESUME_PRIORITY_CPU() ((void)0)
--- a/storage/innobase/include/ut0ut.h
+++ b/storage/innobase/include/ut0ut.h
-@@ -89,8 +89,7 @@ private:
+@@ -70,9 +70,8 @@ typedef time_t ib_time_t;
+ the YieldProcessor macro defined in WinNT.h. It is a CPU architecture-
independent way by using YieldProcessor. */
- # define UT_RELAX_CPU() YieldProcessor()
- # elif defined(__powerpc__)
--#include <sys/platform/ppc.h>
--# define UT_RELAX_CPU() __ppc_get_timebase()
-+# define UT_RELAX_CPU() __builtin_ppc_get_timebase()
- # else
- # define UT_RELAX_CPU() ((void)0) /* avoid warning for an empty statement */
- # endif
-@@ -104,9 +103,8 @@ private:
+ # define UT_RELAX_CPU() YieldProcessor()
+-#elif defined(__powerpc__) && defined __GLIBC__
+-# include <sys/platform/ppc.h>
+-# define UT_RELAX_CPU() __ppc_get_timebase()
++#elif defined(__powerpc__)
++# define UT_RELAX_CPU() __builtin_ppc_get_timebase()
+ #else
+ # define UT_RELAX_CPU() do { \
+ volatile int32 volatile_var; \
+@@ -90,9 +89,8 @@ typedef time_t ib_time_t;
#endif
- # if defined(HAVE_HMT_PRIORITY_INSTRUCTION)
--#include <sys/platform/ppc.h>
--# define UT_LOW_PRIORITY_CPU() __ppc_set_ppr_low()
--# define UT_RESUME_PRIORITY_CPU() __ppc_set_ppr_med()
-+# define UT_LOW_PRIORITY_CPU() __asm__ __volatile__ ("or 1,1,1")
-+# define UT_RESUME_PRIORITY_CPU() __asm__ __volatile__ ("or 2,2,2")
- # else
- # define UT_LOW_PRIORITY_CPU() ((void)0)
- # define UT_RESUME_PRIORITY_CPU() ((void)0)
+ #if defined(HAVE_HMT_PRIORITY_INSTRUCTION)
+-# include <sys/platform/ppc.h>
+-# define UT_LOW_PRIORITY_CPU() __ppc_set_ppr_low()
+-# define UT_RESUME_PRIORITY_CPU() __ppc_set_ppr_med()
++# define UT_LOW_PRIORITY_CPU() __asm__ __volatile__ ("or 1,1,1")
++# define UT_RESUME_PRIORITY_CPU() __asm__ __volatile__ ("or 2,2,2")
+ #else
+ # define UT_LOW_PRIORITY_CPU() ((void)0)
+ # define UT_RESUME_PRIORITY_CPU() ((void)0)