Patchwork [5/5] Use gcc warning flag -Wtype-limits

login
register
mail settings
Submitter Blue Swirl
Date Sept. 4, 2010, 2:18 p.m.
Message ID <AANLkTi=i15pg3=wfKeBkoFFx3DsepmCLFY3zsrpuoHXN@mail.gmail.com>
Download mbox | patch
Permalink /patch/63786/
State New
Headers show

Comments

Blue Swirl - Sept. 4, 2010, 2:18 p.m.
If the compiler supports the warning flag -Wtype-limits, use it.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
---
 configure |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Patch

diff --git a/configure b/configure
index 146dac0..47bbe39 100755
--- a/configure
+++ b/configure
@@ -138,7 +138,7 @@  QEMU_CFLAGS="-D_FORTIFY_SOURCE=2 $QEMU_CFLAGS"
 QEMU_CFLAGS="-I. -I\$(SRC_PATH) $QEMU_CFLAGS"
 LDFLAGS="-g $LDFLAGS"

-gcc_flags="-Wold-style-declaration -Wold-style-definition
-fstack-protector-all"
+gcc_flags="-Wold-style-declaration -Wold-style-definition
-Wtype-limits -fstack-protector-all"
 cat > $TMPC << EOF
 int main(void) { return 0; }
 EOF