mariadb: prevent building against uClibc

MariaDB 10.4 includes some changes in sql/sql_statistics.cc that require
std::fmin and std::fmax. But these functions aren't available when
libstdc++ is compiled against uClibc, because uClibc doesn't pass the
test when libstdc++ checks for C99 math that supports "TR1" facilities
(macro: GLIBCXX_CHECK_C99_TR1).

Hence compilation fails:

[ 90%] Building CXX object sql/CMakeFiles/sql.dir/sql_table.cc.o
/builder/shared-workdir/build/sdk/build_dir/target-arc_archs_uClibc/mariadb-10.4.10/sql/sql_statistics.cc: In member function 'void Column_statistics_collected::finish(ha_rows, double)':
/builder/shared-workdir/build/sdk/build_dir/target-arc_archs_uClibc/mariadb-10.4.10/sql/sql_statistics.cc:2533:20: error: 'fmax' is not a member of 'std'
         val = std::fmax(estimate_total_distincts * (rows - nulls) / rows, 1.0);

This commit updates package dependencies to prevent a build against
uClibc. There is no reason to waste CPU cycles on the build bots.

The dependencies are also tidied up. In the past it made sense to define
MARIADB_COMMON_DEPENDS and MARIADB_COMMON_DEPENDS_EXE, because the
server had different dependencies compared to the library. But since the
library is now in its own package we can remove the differentiation.

Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
This commit is contained in:
Sebastian Kemper 2019-11-20 20:51:21 +01:00
parent 8022b0de7c
commit d792174804
1 changed files with 6 additions and 8 deletions

View File

@ -173,13 +173,11 @@ include $(INCLUDE_DIR)/nls.mk
MARIADB_COMMON_DEPENDS := \
$(ICONV_DEPENDS) \
+libopenssl \
+zlib
MARIADB_COMMON_DEPENDS_EXE := \
$(MARIADB_COMMON_DEPENDS) \
+libatomic \
+libstdcpp
+libopenssl \
+libstdcpp \
+zlib \
@!USE_UCLIBC
# Pass CPPFLAGS in the CFLAGS as otherwise the build system will
# ignore them.
@ -235,7 +233,7 @@ define Package/mariadb-client-base
$(call Package/mariadb/Default)
TITLE:=MariaDB database client base
DEPENDS:=mariadb-common \
$(MARIADB_COMMON_DEPENDS_EXE) \
$(MARIADB_COMMON_DEPENDS) \
+libedit
endef
@ -286,7 +284,7 @@ endef
define Package/mariadb-server-base
$(call Package/mariadb/Default)
DEPENDS:=mariadb-common \
$(MARIADB_COMMON_DEPENDS_EXE) \
$(MARIADB_COMMON_DEPENDS) \
+libaio \
+liblzma \
+libpcre \