Re: configure.in and setproctitle/optreset problem - Mailing list pgsql-hackers

From Tom Lane
Subject Re: configure.in and setproctitle/optreset problem
Date
Msg-id 8705.1355845633@sss.pgh.pa.us
Whole thread Raw
In response to Re: configure.in and setproctitle/optreset problem  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: configure.in and setproctitle/optreset problem  (Christoph Berg <christoph.berg@credativ.de>)
List pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> On Mon, 2012-12-17 at 18:02 +0100, Christoph Berg wrote:
>> I have no clue why no one else has seen this bug before, but the
>> reason for the error seems to be that configure is invoking the
>> setproctitle test including -ledit. libedit.so is linked to libbsd.so,
>> which in turn contains setproctitle(), so HAVE_SETPROCTITLE is set
>> even this is Linux, not BSD. 

> I reported this here:
> http://archives.postgresql.org/pgsql-bugs/2012-07/msg00127.php

I thought the issue sounded familiar ...

> The correct fix, IMO/IIRC, is to add LDFLAGS=-Wl,--as-needed before
> running most of the configure checks, instead of after.

Meh.  It's not clear to me at all that that fixes the issue here,
or at least that it does so in any way that's reliable.  The proposal
to add --as-needed during configure was made to fix a different problem,
namely making the wrong decision about whether libintl needs to be
pulled in explicitly.  We don't seem to have done anything about that
--- personally I was afraid that it could break as many cases as it
fixed.  Reviewing that thread, I still think that swapping the order
of the probes for libintl and libgssapi is the safest fix for the
previous issue.
        regards, tom lane



pgsql-hackers by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: Enabling Checksums
Next
From: Greg Stark
Date:
Subject: Re: Enabling Checksums