dev-db/mariadb: workaround unaligned access

Pass -fno-tree-vectorize with GCC 16 for now. I've reported it upstream
to MariaDB and they've acknowledged the problem. Note that the "same"
code is in MySQL but that was fixed quite some years back.

Bug: https://jira.mariadb.org/browse/MDEV-37148
Closes: https://bugs.gentoo.org/959423
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James
2025-08-08 09:18:49 +01:00
parent 82964175b7
commit d72826a5df
5 changed files with 15 additions and 0 deletions

View File

@@ -303,6 +303,9 @@ src_configure() {
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
# Workaround for bug #959423 (https://jira.mariadb.org/browse/MDEV-37148)
tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-flags -fno-tree-vectorize
# debug hack wrt #497532
local mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"

View File

@@ -315,6 +315,9 @@ src_configure() {
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
# Workaround for bug #959423 (https://jira.mariadb.org/browse/MDEV-37148)
tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-flags -fno-tree-vectorize
CMAKE_BUILD_TYPE="RelWithDebInfo"
# debug hack wrt #497532

View File

@@ -309,6 +309,9 @@ src_configure() {
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
# Workaround for bug #959423 (https://jira.mariadb.org/browse/MDEV-37148)
tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-flags -fno-tree-vectorize
# debug hack wrt #497532
local mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"

View File

@@ -299,6 +299,9 @@ src_configure() {
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
# Workaround for bug #959423 (https://jira.mariadb.org/browse/MDEV-37148)
tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-flags -fno-tree-vectorize
# debug hack wrt #497532
local mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"

View File

@@ -299,6 +299,9 @@ src_configure() {
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
# Workaround for bug #959423 (https://jira.mariadb.org/browse/MDEV-37148)
tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-flags -fno-tree-vectorize
# debug hack wrt #497532
local mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"