[CFT] Add -Wbounded to gcc

Pedro Giffuni pfg at FreeBSD.org
Wed Jul 11 03:41:23 UTC 2012


Hello;

I have a patch from OpenBSD that adds -Wbounded to gcc:

http://people.freebsd.org/~pfg/patches/patch-gcc-bounded

Unfortunately it breaks world, or at least binutils, at this time:

_________
...
cc1: warnings being treated as errors
peigen.c: In function '_bfd_pei_swap_aux_in':
peigen.c:241: warning: array size (14) smaller than bound length (18)
peigen.c:241: warning: array size (14) smaller than bound length (18)
peigen.c: In function '_bfd_pei_swap_aux_out':
peigen.c:314: warning: array size (14) smaller than bound length (18)
peigen.c:314: warning: array size (14) smaller than bound length (18)
*** Error code 1

Stop in /usr/src/gnu/usr.bin/binutils/libbfd.
*** Error code 1

Stop in /usr/src/gnu/usr.bin/binutils.
___________

OpenBSD has a fix but before attempting to clean this, and whatever
else would break, I can't help but ask: is it worth it?

best regards,

Pedro.


More information about the freebsd-current mailing list