Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled - Mailing list pgsql-bugs

From Andres Freund
Subject Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled
Date
Msg-id 20130725135854.GD15081@alap2.anarazel.de
Whole thread Raw
In response to Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
On 2013-07-25 09:48:31 -0400, Tom Lane wrote:
> Andres Freund <andres@2ndquadrant.com> writes:
> >> Before that commit the checks for cmsgcred which includes sys/ucred.h
> >> happened to include params.h... Patch attached, missing the configure
> >> update since I don't have a compatible autoconf on my laptop, to produce
> >> a minimal diff.
>
> > Could somebody apply the fix (including regenerating /configure)?
>
> The proposed patch seems a bit overcomplicated --- isn't the real
> problem that I changed the ordering of the header probes in
> be4585b1c27ac5dbdd0d61740d18f7ad9a00e268?  I think I just alphabetized
> them in a fit of neatnik-ism, not realizing that there were order
> dependencies on some platforms.

Hm. It very well might be too complicated. I am not exactly a autoconf
expert...
The problem is that you can't include sys/ucred.h on some platforms
(e.g. openbsd) without first including sys/params.h because the
resulting file won't compile. Unless I misunderstood what you propose a
different order in that AC_CHECK_HEADERS() shouldn't help getting it
there?
Maybe we could get rid of the two separate tests that now use
HAVE_SYS_PARAM_H - I just tried to followed the surrounding patterns.

FWIW I have confirmation via private emails that the patch works at
least on openbsd...

Greetings,

Andres Freund

--
 Andres Freund                       http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled
Next
From: Tom Lane
Date:
Subject: Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled