[PATCH] backends: Ignore GCC8 -Wpacked-not-aligned for m68k_corenote.c.
Thu Oct 26 14:28:00 GMT 2017
On Tue, 2017-10-24 at 14:35 +0200, Mark Wielaard wrote:
> The GCC8 -Wpacked-not-aligned warns if a structure field with explicit
> padding in a packed structure will be misaligned. m68k prstatus core
> notes are described by a packed structure which has such aligned structure
Well, that worked, but only because of two typos canceling each other
> +# m68k prstatus core notes are described by a packed structure
> +# which has not naturally aligned fields. Since we don't access
> +# these fields directly, but take their offset to be used later
> +# to extract the data through elfxx_xlatetom/memmove, this isn't
> +# an issue.
> +m68k_corenote_Wpacked_not_aligned = yes
Missing no_ ...
> +++ b/config/eu.am
> @@ -74,6 +74,7 @@ AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \
> > $(if $($(*F)_no_Werror),,-Werror) \
> > $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \
> > $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \
> > + $(if $($(*F)_no_Wpacked_not_aligned),,-Wno-packed-not-aligned) \
Double ,, causing everything to get -Wno-packaged-not-aligned.
Oops. Fixed patch attached.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 2595 bytes
More information about the Elfutils-devel