Add -Wno-psabi to CFLAGS for x86 (32-bit) builds

GCC 11.1+ emits a note during compilation when there are 64-bit
atomic fields in a structure, because it fixed a compiler bug
by changing the alignment of such fields, which caused ABI change.

Add -Wno-psabi to CFLAGS for such builds in order to silence the
warning. That shouldn't be a problem since we don't expose our
structures to the outside.
This commit is contained in:
Aram Sargsyan 2024-08-15 10:28:40 +00:00 committed by Arаm Sаrgsyаn
parent 936975a9ae
commit 867066aa53

View file

@ -133,6 +133,9 @@ AC_COMPILE_IFELSE(
[],
[STD_CFLAGS="$STD_CFLAGS -Wno-stringop-overread"])
# Silence GCC 11.1+ note about the changed alignment, see GL #4841
AS_CASE([$target_cpu],[i?86],[STD_CFLAGS="$STD_CFLAGS -Wno-psabi"])
STD_LDFLAGS=""
# ... except in test code