Bug#367657: GCC new warnings and compatibility
On Wed, May 17, 2006 at 03:14:04PM +0100, Ian Jackson wrote:
> Furthermore, because GCC has traditionally had such good warnings, and
> such good configurability of warnings, and because no-one looks at
> warnings that don't cause build failures, many people (myself
> included) use -Werror in nearly all of their projects.
If you're using autotools, you could do the following as a workaround.
AC_HELP_STRING(--enable-warnings-as-errors,Treat warnings as errors (default off),
AM_CONDITIONAL(WARN, test "$WARN_IS_ERR" = yes)
AM_CFLAGS += -Werror
If you do that, then run configure with --enable-warnings-as-errors,
you'll get -Werror on your compiler command line, and not otherwise.
If you don't use autotools, you could just say make CFLAGS='-Werror',
which would also work.
Fun will now commence
-- Seven Of Nine, "Ashes to Ashes", stardate 53679.4