Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled

From: Andres Freund <andres(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Emre Hasegeli <emre(at)hasegeli(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled
Date: 2013-07-25 13:58:54
Message-ID: 20130725135854.GD15081@alap2.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 2013-07-25 09:48:31 -0400, Tom Lane wrote:
> Andres Freund <andres(at)2ndquadrant(dot)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

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2013-07-25 14:48:56 Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled
Previous Message Tom Lane 2013-07-25 13:48:31 Re: BUG #8271: Configure warning: sys/ucred.h: present but cannot be compiled