BasisUniversal: Disable strict aliasing to fix GCC optimization issue

This is flagged by upstream as something important in `basisu.h`.
And indeed, we've now seen why with a regression appearing with mingw-gcc 15.

Fixes #114803.
This commit is contained in:
Rémi Verschelde
2026-01-10 23:06:21 +01:00
committed by Rémi Verschelde
parent 94971e1b47
commit 16daea3622

View File

@@ -56,6 +56,10 @@ if env["builtin_zstd"]:
env_thirdparty = env_basisu.Clone()
env_thirdparty.disable_warnings()
if not env.msvc:
# Required by upstream for GCC. Enabling also for LLVM-based compilers to be consistent.
env_thirdparty.Append(CCFLAGS=["-fno-strict-aliasing"])
# Disable unneeded features to reduce binary size.
# <https://github.com/BinomialLLC/basis_universal/wiki/How-to-Use-and-Configure-the-Transcoder>
env_thirdparty.Append(