Re: [HACKERS] pg_recvlogical.c doesn't build with --disable-integer-datetimes - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] pg_recvlogical.c doesn't build with --disable-integer-datetimes
Date
Msg-id 25938.1487367117@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] pg_recvlogical.c doesn't build with --disable-integer-datetimes  (Mark Dilger <hornschnorter@gmail.com>)
Responses Re: [HACKERS] pg_recvlogical.c doesn't build with --disable-integer-datetimes  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Mark Dilger <hornschnorter@gmail.com> writes:
>  if test "$GCC" = yes -a "$ICC" = no; then
>    CFLAGS="-Wall -Wmissing-prototypes -Wpointer-arith"
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wempty-body])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wignored-qualifiers])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wimplicit-fallthrough])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wtype-limits])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wuninitialized])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wshift-negative-value])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wmissing-include-dirs])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wshift-overflow])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wswitch-default])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wdangling-else])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Waggregate-return])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wstrict-prototypes])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wmissing-declarations])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wredundant-decls])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Winline])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Woverlength-strings])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wc++-compat])
> +  PGAC_PROG_CC_CFLAGS_OPT([-Wold-style-definition])
>    # These work in some but not all gcc versions
>    PGAC_PROG_CC_CFLAGS_OPT([-Wdeclaration-after-statement])
>    PGAC_PROG_CC_CFLAGS_OPT([-Wendif-labels])

I'm not terribly for that.  For the most part, if a gcc warning isn't
included by '-Wall', there's a reason for it.  We could talk about
whether individual extra warnings are useful for the Postgres project,
but I don't want to suddenly move the goalposts to where we are
enforcing a bunch of pedantic warnings that different compiler versions
might not even interpret the same.  I'm particularly not for turning
them up in the way you suggest here, where violations would result in
buildfarm failures on machines running with -Werror.

Right now I'd rather focus on getting to where we can have -Werror on in
the buildfarm at all.  longfin says we've got work to do on that, at least
in the back branches.  It may be that we can't expect near-EOL branches to
always compile perfectly cleanly on newer compilers.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: [HACKERS] pg_recvlogical.c doesn't build with --disable-integer-datetimes
Next
From: Peter Eisentraut
Date:
Subject: Re: [HACKERS] SUBSCRIPTIONS and pg_upgrade