aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2021-06-15 22:48:07 -0700
committerArmin Kuster <akuster808@gmail.com>2021-07-18 08:47:57 -0700
commita6ec992b3f2fa9a9762962eb18087193b8293e4c (patch)
tree757bbfc613275bd7b524acd17563b67c47a4f2cd
parent9aad47d679f0453fe354409afa5f19ac4179958d (diff)
downloadmeta-openembedded-a6ec992b3f2fa9a9762962eb18087193b8293e4c.tar.gz
meta-openembedded-a6ec992b3f2fa9a9762962eb18087193b8293e4c.tar.bz2
meta-openembedded-a6ec992b3f2fa9a9762962eb18087193b8293e4c.zip
mariadb: Fix build with clang/musl
Signed-off-by: Khem Raj <raj.khem@gmail.com> (cherry picked from commit abbca30bd61c0ff856785900aac899ab33ead08b) Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--meta-oe/recipes-dbs/mysql/mariadb.inc1
-rw-r--r--meta-oe/recipes-dbs/mysql/mariadb/mm_malloc.patch11
2 files changed, 12 insertions, 0 deletions
diff --git a/meta-oe/recipes-dbs/mysql/mariadb.inc b/meta-oe/recipes-dbs/mysql/mariadb.inc
index 25e630a16..18b025070 100644
--- a/meta-oe/recipes-dbs/mysql/mariadb.inc
+++ b/meta-oe/recipes-dbs/mysql/mariadb.inc
@@ -23,6 +23,7 @@ SRC_URI = "https://downloads.mariadb.org/interstitial/${BP}/source/${BP}.tar.gz
file://sys_futex.patch \
file://cross-compiling.patch \
file://ssize_t.patch \
+ file://mm_malloc.patch \
"
SRC_URI_append_libc-musl = " file://ppc-remove-glibc-dep.patch"
diff --git a/meta-oe/recipes-dbs/mysql/mariadb/mm_malloc.patch b/meta-oe/recipes-dbs/mysql/mariadb/mm_malloc.patch
new file mode 100644
index 000000000..347fcd851
--- /dev/null
+++ b/meta-oe/recipes-dbs/mysql/mariadb/mm_malloc.patch
@@ -0,0 +1,11 @@
+--- a/storage/rocksdb/rocksdb/port/jemalloc_helper.h
++++ b/storage/rocksdb/rocksdb/port/jemalloc_helper.h
+@@ -5,7 +5,7 @@
+
+ #pragma once
+
+-#if defined(__clang__)
++#if defined(__clang__) && defined(__GLIBC__)
+ // glibc's `posix_memalign()` declaration specifies `throw()` while clang's
+ // declaration does not. There is a hack in clang to make its re-declaration
+ // compatible with glibc's if they are declared consecutively. That hack breaks