aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-09-15 12:27:28 +0200
committerMax Kellermann <max@duempel.org>2008-09-15 12:27:28 +0200
commit7d98fb19dc2b7c3af289b0a7c1a0db68e7fea8c9 (patch)
tree57a18b76a1815dff1a9083c9b812feedce6aa694 /configure.ac
parent629401644d03c1fc57895409b74ea8267c276a4b (diff)
downloadmpd-7d98fb19dc2b7c3af289b0a7c1a0db68e7fea8c9.tar.gz
mpd-7d98fb19dc2b7c3af289b0a7c1a0db68e7fea8c9.tar.xz
mpd-7d98fb19dc2b7c3af289b0a7c1a0db68e7fea8c9.zip
enable gcc warnings
Enable all useful warnings which were also enabled in MPD. Steal m4/mpd_check_cflag.m4 from MPD.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac17
1 files changed, 16 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 3ffc87009..16a13571d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -206,9 +206,24 @@ AC_ARG_ENABLE([debug],
[enable_debug=no])
AC_MSG_RESULT([$enable_debug])
if test "x$enable_debug" = "xyes" ; then
- CFLAGS="$CFLAGS -Wall -g -DDEBUG"
+ CFLAGS="$CFLAGS -g -DDEBUG"
fi
+dnl CFLAGS
+
+AC_SUBST(AM_CFLAGS)
+
+CHECK_CFLAG([-Wall])
+CHECK_CFLAG([-Wextra])
+CHECK_CFLAG([-Wno-deprecated-declarations])
+CHECK_CFLAG([-Wmissing-prototypes])
+CHECK_CFLAG([-Wdeclaration-after-statement])
+CHECK_CFLAG([-Wshadow])
+CHECK_CFLAG([-Wpointer-arith])
+CHECK_CFLAG([-Wstrict-prototypes])
+CHECK_CFLAG([-Wcast-qual])
+CHECK_CFLAG([-Wwrite-strings])
+
dnl Optional screen - help screen
#AC_MSG_CHECKING([whether to include the help screen])
#AC_ARG_ENABLE([help-screen],