On Fri, Jan 03, 2014 at 10:22:27PM +0100, Vincent Lefevre wrote:
> Package: autoconf
> Version: 2.69-2
> Severity: minor
>
> A developer may want to test his software with
> -Werror=old-style-definition (in particular because such definitions
> could be a real bug in the software). But configure fails because
> autoconf generates such a function definition. For instance:
In my opinion, it's a mistake to run "configure" tests with -Werror. I
suggest adding such flags after configure tests have been run, as with
the --enable-Werror configure flag supported by Open vSwitch:
dnl OVS_ENABLE_WERROR
AC_DEFUN([OVS_ENABLE_WERROR],
[AC_ARG_ENABLE(
[Werror],
[AC_HELP_STRING([--enable-Werror], [Add -Werror to CFLAGS])],
[], [enable_Werror=no])
AC_CONFIG_COMMANDS_PRE(
[if test "X$enable_Werror" = Xyes; then
CFLAGS="$CFLAGS -Werror"
fi])])
I guess that -Werror=old-style-definition is somewhat more restricted,
but a similar solution can be used.
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]