Christian Hesse pushed to branch main at Arch Linux / Packaging / Packages / 
mysql-workbench


Commits:
93a9862f by Niels P at 2026-08-13T19:06:32+02:00
Add -fsigned-char on aarch64 (MySQL char signedness assumption)

MySQL source code assumes char is signed in multiple locations,
particularly in library/sql.parser/source/ctype-utf8.cpp where char
arrays are initialized with -1 values. On aarch64 where char is
unsigned by default, this causes narrowing conversion errors.

This is a long-standing upstream MySQL issue, acknowledged but unfixed:
- Bug #60910 (2011): 'Some MySQL source code assumes char is signed'
  MySQL's own recommendation: 'When we added -fsigned-char, the
  problems cleared up.'
- Bug #78950 (2015): 'narrowing conversion of -1 from int to char'
- Bug #87543 (2017): 'dd_sdi-t.cc assumes char to be signed' on AArch64

Adding -fsigned-char for aarch64 matches x86 behavior and is the
upstream-recommended workaround.

Tested on aarch64 (Graviton 4, GCC 16.3.0).

- - - - -


1 changed file:

- PKGBUILD


Changes:

=====================================
PKGBUILD
=====================================
@@ -165,6 +165,10 @@ build() {
        echo "Install mysql-connector-c++..."
        make DESTDIR="${srcdir}/install-bundle/" install
 
+       # MySQL source assumes char is signed (Bug #60910, #78950, #87543 — 
unfixed since 2011).
+       # On aarch64, char is unsigned by default, causing narrowing conversion 
errors in ctype-utf8.cpp.
+       CXXFLAGS+=" -fsigned-char"
+
        # Build MySQL Workbench itself with bundled libs
        mkdir "${srcdir}/mysql-workbench-community-${pkgver}-src-build"
        cd "${srcdir}/mysql-workbench-community-${pkgver}-src-build"



View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/mysql-workbench/-/commit/93a9862ff01674cfc840a6f52127558751ad2c1e

-- 
View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/mysql-workbench/-/commit/93a9862ff01674cfc840a6f52127558751ad2c1e
You're receiving this email because of your account on gitlab.archlinux.org. 
Manage all notifications: https://gitlab.archlinux.org/-/profile/notifications 
| Help: https://gitlab.archlinux.org/help


Reply via email to