Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-15 Thread Andres Freund
On 2015-01-15 09:25:29 -0500, Tom Lane wrote: > Andres Freund writes: > > FWIW, if we moved the > > CFLAGS="$CFLAGS $user_CFLAGS" > > further down, it'd have advantage that compiling with -Werror would be > > more realistic. Right now doing so breaks about half of the feature > > checking configur

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-15 Thread Tom Lane
Andres Freund writes: > FWIW, if we moved the > CFLAGS="$CFLAGS $user_CFLAGS" > further down, it'd have advantage that compiling with -Werror would be > more realistic. Right now doing so breaks about half of the feature > checking configure checks because of warnings. E.g. on my platform it > fai

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-15 Thread Andres Freund
On 2015-01-14 09:34:23 -0500, Tom Lane wrote: > Andres Freund writes: > > On 2015-01-13 22:19:30 -0500, Tom Lane wrote: > >> A slightly more complicated change could be applied to make sure that > >> *all* of the CFLAGS forcibly inserted by configure appear before any > >> externally-sourced CFLAG

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Andres Freund
On 2015-01-14 11:09:10 -0500, Tom Lane wrote: > Andres Freund writes: > > I've already given up... Given how infrequent it is, suppressing it for > > gull seems sufficient. > > I'm confused --- I see no format warnings in gull's current reports. Sorry it was me being confused. I somehow switched

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Tom Lane
Andres Freund writes: > I've already given up... Given how infrequent it is, suppressing it for > gull seems sufficient. I'm confused --- I see no format warnings in gull's current reports. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgre

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Andres Freund
On 2015-01-14 10:01:39 -0500, Tom Lane wrote: > Andres Freund writes: > > On 2015-01-14 09:34:23 -0500, Tom Lane wrote: > >> Well, that would only fix my problem if we added a configure-time test > >> for whether gcc recognizes "z", which frankly seems like a waste of > >> cycles. I've probably g

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Tom Lane
Andres Freund writes: > On 2015-01-14 09:34:23 -0500, Tom Lane wrote: >> Well, that would only fix my problem if we added a configure-time test >> for whether gcc recognizes "z", which frankly seems like a waste of >> cycles. I've probably got the last one left in captivity that doesn't. > Hm. I

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Andres Freund
On 2015-01-14 09:34:23 -0500, Tom Lane wrote: > Andres Freund writes: > > On 2015-01-13 22:19:30 -0500, Tom Lane wrote: > >> The reason I got interested in this is that I attempted to pass in > >> "CFLAGS=-Wno-format" to configure, to suppress format warnings on > >> buildfarm member gaur (whose g

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Tom Lane
Andres Freund writes: > On 2015-01-13 22:19:30 -0500, Tom Lane wrote: >> The reason I got interested in this is that I attempted to pass in >> "CFLAGS=-Wno-format" to configure, to suppress format warnings on >> buildfarm member gaur (whose gcc is too old to recognize z modifiers). >> That doesn't

Re: [HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-14 Thread Andres Freund
Hi Tom, On 2015-01-13 22:19:30 -0500, Tom Lane wrote: > Would anyone object to modifying configure.in like this: > > if test "$GCC" = yes -a "$ICC" = no; then > - CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith" > + CFLAGS="-Wall $CFLAGS -Wmissing-prototypes -Wpointer-arith" >#

[HACKERS] Minor configure tweak to simplify adjusting gcc warnings

2015-01-13 Thread Tom Lane
Would anyone object to modifying configure.in like this: if test "$GCC" = yes -a "$ICC" = no; then - CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith" + CFLAGS="-Wall $CFLAGS -Wmissing-prototypes -Wpointer-arith" # These work in some but not all gcc versions PGAC_PROG_CC_CFLAGS