[Telepathy-commits] [telepathy-salut/master] be as anal as Gabble with compiler flags

Guillaume Desmottes guillaume.desmottes at collabora.co.uk
Fri Dec 12 07:55:31 PST 2008


---
 configure.ac |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/configure.ac b/configure.ac
index a81067d..c874f57 100644
--- a/configure.ac
+++ b/configure.ac
@@ -41,12 +41,26 @@ SALUT_ARG_COVERAGE
 dnl decide error flags
 AS_COMPILER_FLAG(-Wall, ERROR_CFLAGS="-Wall", ERROR_CFLAGS="")
 
+AS_COMPILER_FLAG(-Wextra, wextra=yes, wextra=no)
+AS_COMPILER_FLAG(-Wno-missing-field-initializers,
+        wno_missing_field_initializers=yes,
+        wno_missing_field_initializers=no)
+AS_COMPILER_FLAG(-Wno-unused-parameter,
+        wno_unused_parameter=yes,
+        wno_unused_parameter=no)
+
 ifelse(salut_nano_version, 0,
     [],
     [AS_COMPILER_FLAG(-Werror,ERROR_CFLAGS="$ERROR_CFLAGS -Werror",ERROR_CFLAGS="$ERROR_CFLAGS")
     ])
 AC_SUBST(ERROR_CFLAGS)
 
+AS_COMPILER_FLAG(-Wdeclaration-after-statement, ERROR_CFLAGS="$ERROR_CFLAGS -Wdeclaration-after-statement")
+AS_COMPILER_FLAG(-Wshadow, ERROR_CFLAGS="$ERROR_CFLAGS -Wshadow")
+AS_COMPILER_FLAG(-Wstrict-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wstrict-prototypes")
+AS_COMPILER_FLAG(-Wmissing-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-prototypes")
+AS_COMPILER_FLAG(-Wmissing-declarations, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-declarations")
+
 ifelse(salut_nano_version, 0,
     [ # Salut is version x.y.z - disable coding style checks by default
 AC_ARG_ENABLE(coding-style-checks,
-- 
1.5.6.5




More information about the Telepathy-commits mailing list