From: Seneca Cunningham <scunning@ca.afilias.info>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: dba@ca.afilias.info
Cc: pgsql-ports@postgresql.org
Cc: Mark Gibson <gibsonm@cromwell.co.uk>
Cc: stefan@kaltenbrunner.cc
Subject: Re: Patchless postgres 8.x on AIX
Date: Thu, 17 Nov 2005 11:20:15 -0500
Message-ID: <437CADBF.80904@ca.afilias.info> (raw)
In-Reply-To: <13111.1132183705@sss.pgh.pa.us>
References: <437BB3C6.6050204@ca.afilias.info>
<13111.1132183705@sss.pgh.pa.us>
Tom Lane wrote:
> Seneca Cunningham <scunning@ca.afilias.info> writes:
>
>>What is happening with postgres certainly appears to be related to the
>>linker; in dynahash.c, the keycopy functions that work with no new
>>linker flags (strncpy, memmove worked as a memcpy replacement) are all
>>exported by libreadline.a, while the segfaulting/infinite-looping memcpy
>>is not.
>
>
> libreadline exports these?? I'd say you have a seriously braindead copy
> of libreadline ... can you recompile a fresh copy off the net?
That was just IBM's rpm of readline 4.3, my fresh build of readline 5.0
exports memcpy in addition to the aforementioned functions. As a
result, LDFLAGS-less postgres doesn't segfault but it gets its memcpy
linked through libreadline. libreadline's build scripts, at least for
5.0, don't seem to give a build that can be properly linked against on
AIX, and it's entirely possible that my build used different linker
flags than IBM's to get a libreadline that actually exports what it
provides.
> The inet failures look like there is consistently no support for IPv6.
> I wonder if the linker is somehow replacing our own inet-parsing
> subroutines with a non-IPv6-aware set. It's conceivable that there
> could be a name collision with subroutines from an old version of
> libbind.
The linker appears to be grabbing the inet functions from the AIX libc,
not the postgres set. LDFLAGS is placed before all the SUBSYS.o, and by
my understanding of the AIX linker, adding "-lc" to LDFLAGS would cause
it to search libc.a before utils/SUBSYS.o and use the functions like
inet_net_pton from libc.
--
Seneca Cunningham
scunning@ca.afilias.info
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-ports@postgresql.org
Cc: scunning@ca.afilias.info, tgl@sss.pgh.pa.us, dba@ca.afilias.info, gibsonm@cromwell.co.uk, stefan@kaltenbrunner.cc
Subject: Re: Patchless postgres 8.x on AIX
In-Reply-To: <437CADBF.80904@ca.afilias.info>
References: <437BB3C6.6050204@ca.afilias.info> <13111.1132183705@sss.pgh.pa.us> <437CADBF.80904@ca.afilias.info>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox