Enable -Wall by default. SDL-1.2
authorRyan C. Gordon <icculus@icculus.org>
Tue, 11 Oct 2011 22:04:51 -0400
branchSDL-1.2
changeset 5976081c94f2c04a
parent 5960 eb025734b5a1
child 5983 1361a12b2e58
Enable -Wall by default.

Fixes Bugzilla #1284.

(But probably upsets buildbot. :) )
(transplanted from 516c5c4e7beabd27608c67cab5b0259643a9083c)
configure.in
     1.1 --- a/configure.in	Mon Sep 19 01:46:55 2011 -0400
     1.2 +++ b/configure.in	Tue Oct 11 22:04:51 2011 -0400
     1.3 @@ -875,6 +875,28 @@
     1.4      fi
     1.5  }
     1.6  
     1.7 +dnl See if GCC's -Wall is supported.
     1.8 +CheckWarnAll()
     1.9 +{
    1.10 +    AC_MSG_CHECKING(for GCC -Wall option)
    1.11 +    have_gcc_Wall=no
    1.12 +
    1.13 +    save_CFLAGS="$CFLAGS"
    1.14 +    CFLAGS="$save_CFLAGS -Wall"
    1.15 +    AC_TRY_COMPILE([
    1.16 +    int x = 0;
    1.17 +    ],[
    1.18 +    ],[
    1.19 +    have_gcc_Wall=yes
    1.20 +    ])
    1.21 +    AC_MSG_RESULT($have_gcc_Wall)
    1.22 +    CFLAGS="$save_CFLAGS"
    1.23 +
    1.24 +    if test x$have_gcc_Wall = xyes; then
    1.25 +        EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
    1.26 +    fi
    1.27 +}
    1.28 +
    1.29  
    1.30  dnl Do the iPod thing
    1.31  CheckIPod()
    1.32 @@ -2785,6 +2807,9 @@
    1.33          ;;
    1.34  esac
    1.35  
    1.36 +dnl Do this on all platforms, after everything else.
    1.37 +CheckWarnAll
    1.38 +
    1.39  # Verify that we have all the platform specific files we need
    1.40  
    1.41  if test x$enable_joystick = xyes; then