[ipxe-devel] Upcoming gcc 9 has issues with ipxe source

Bruce Rogers brogers at suse.com
Wed Jan 23 23:07:44 UTC 2019


An early look at gcc 9 compatibility with packages built in the OpenSUSE Build Service
shows that the ipxe sources hit up against a new warning, which is documented as follows:

-Waddress-of-packed-member, enabled by default, warns about an unaligned pointer
value from the address of a packed member of a struct or union.

This issue is reported in this openSUSE bug report: https://bugzilla.opensuse.org/show_bug.cgi?id=1121464

I started to create a patch to address the instance in the bug report, but then found out
that taking the address of members in packed structures is fairly common in the code,
so I figured I'd first ask if someone is already looking into this or what solution would
be best.

It's probably reasonable to simply silence this warning in the make system, since I don't
think moving to gcc 9 and ignoring this new warning adds risk, but it does point out
a portability and performance issue with the code which may be worth fixing.

I'd be happy to help provide code fixes, but don't want to jump the gun if people
think silencing the warning is the solution.


More information about the ipxe-devel mailing list