kernel: Disable -Winline and -Wunused-but-set-variable for buildkernel.
authorSascha Wildner <saw@online.de>
Tue, 12 Mar 2013 20:45:37 +0000 (21:45 +0100)
committerSascha Wildner <saw@online.de>
Tue, 12 Mar 2013 20:45:37 +0000 (21:45 +0100)
commit11116d3f7774893093025614fdf0ca2fff628876
treee6b5d6011b2bb787081ca213123e90b1185364cc
parenta1f2c914b8cd6ce8baa22478c7c2d7b1b1288b6d
kernel: Disable -Winline and -Wunused-but-set-variable for buildkernel.

-Winline's behavior is kind of unobvious to fix without further knowledge
about how the compiler decides what can be inlined and what not. A better
solution might be to remove "inline" from most declarations and instead
use __always_inline for what we absolutely need to inline.

-Wunused-but-set-variable (a gcc47 specific warning) is nice and can
point at places that need cleaning up (which we did for a lot of its
warnings) but at the end of the day, it doesn't catch many real bugs and
it also warns about some cases that we'd like to stay as they are, simply
because it's more convenient or would result in unnecessarily silly code.
We also moved it to WARNS=6 (from WARNS=2) for userland code.

Thanks to aggelos and sephe for sharing their thoughts.
sys/conf/bsd.kern.mk