Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-27 Thread Peter Eisentraut
On tor, 2011-05-26 at 17:31 -0400, Tom Lane wrote: > > We could also do that globally, but that would probably be something > for > > the next release. > > Hmm. I'm a bit scared of how much might break. I don't think the > autoconf tests are generally designed to guarantee no warnings. Yeah, I

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-27 Thread Ibrar Ahmed
On Fri, May 27, 2011 at 2:31 AM, Tom Lane wrote: > Peter Eisentraut writes: > > On tor, 2011-05-26 at 12:14 -0400, Tom Lane wrote: > >> I tried this on my HP-UX 10.20 box, and it didn't work very nicely: > >> configure decided that the compiler accepted +Olibmerrno, so I got a > >> compile full

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-26 Thread Tom Lane
Peter Eisentraut writes: > On tor, 2011-05-26 at 12:14 -0400, Tom Lane wrote: >> I tried this on my HP-UX 10.20 box, and it didn't work very nicely: >> configure decided that the compiler accepted +Olibmerrno, so I got a >> compile full of >> cc: warning 450: Unrecognized option +Olibmerrno.

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-26 Thread Peter Eisentraut
On tor, 2011-05-26 at 12:14 -0400, Tom Lane wrote: > Ibrar Ahmed writes: > > Please find the updated patch. I have added this "+Olibmerrno" compile flag > > check in configure/configure.in file. > > I tried this on my HP-UX 10.20 box, and it didn't work very nicely: > configure decided that the c

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-26 Thread Tom Lane
Ibrar Ahmed writes: > Please find the updated patch. I have added this "+Olibmerrno" compile flag > check in configure/configure.in file. I tried this on my HP-UX 10.20 box, and it didn't work very nicely: configure decided that the compiler accepted +Olibmerrno, so I got a compile full of

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-25 Thread Ibrar Ahmed
Please find the updated patch. I have added this "+Olibmerrno" compile flag check in configure/configure.in file. OS HP-UX B.11.31 U ia64 without patch --- postgres=# select acos(2); acos -- NaN (1 row) with patch --- postgres=# select acos(2); ERROR: input is

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Tom Lane
Heikki Linnakangas writes: > So the default is indeed non-standard. But I wonder if we should use -Aa > instead? Probably not; at least on older HPUX versions, -Aa turns off access to assorted stuff that we do want, eg "long long". "man cc" on my box saith -Amode Specify the compi

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Heikki Linnakangas
On 24.05.2011 20:56, Andrew Dunstan wrote: I have been whining for years about the lack of HP-UX support (both for gcc and their compiler) on the buildfarm. I really really wish HP would come to the party and supply some equipment and software. Failing that, some spare cycles being made available

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Heikki Linnakangas
On 24.05.2011 20:44, Tom Lane wrote: BTW, is it really true that HP decided they could make the compiler's default behavior violate the C standard so flagrantly? I could believe offering a switch that you had to specify to save a few cycles at the cost of nonstandard behavior; but if your report

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Andrew Dunstan
On 05/24/2011 01:44 PM, Tom Lane wrote: Ibrar Ahmed writes: I have found a problem which is specifically related to "HP-UX" compiler. All 'libm' functions on "HP-UX Integrity server" do not set "errno" by default. For 'errno' setting we should compile the code using +Olibmerrno option. So we

Re: [HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Tom Lane
Ibrar Ahmed writes: > I have found a problem which is specifically related to "HP-UX" compiler. > All 'libm' functions on "HP-UX Integrity server" do not set "errno" by > default. For 'errno' setting we should compile the code using +Olibmerrno > option. So we should add this option in "/src/make

[HACKERS] "errno" not set in case of "libm" functions (HPUX)

2011-05-24 Thread Ibrar Ahmed
I have found a problem which is specifically related to "HP-UX" compiler. All 'libm' functions on "HP-UX Integrity server" do not set "errno" by default. For 'errno' setting we should compile the code using +Olibmerrno option. So we should add this option in "/src/makefiles/Makefile.hpux". Otherwi