Re: [PATCHES] HEAD doesn't cope with libraries in non-default

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: "Andrew Dunstan" <andrew(at)dunslane(dot)net>
Cc: pgman(at)candle(dot)pha(dot)pa(dot)us, tgl(at)sss(dot)pgh(dot)pa(dot)us, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCHES] HEAD doesn't cope with libraries in non-default
Date: 2005-07-04 15:58:27
Message-ID: 200507041758.28526.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Andrew Dunstan wrote:
> I was also slightly dubious about it. However, we do still need to
> solve the problem that the patch addressed. Buildfarm members
> platypus and cuckoo are currently failing because dblink is picking
> up the wrong libpq (and it appears that incorrect libraries are also
> being picked up in the ecpg libraries, although this isn't causing a
> buildfarm failure.)

We have four pieces of information when linking a shared library:

B: in-tree libraries that we might need (in case of ecpglib: libpq)
A: path to those in-tree libraries
D: external libraries that we might need (in case of ecpglib in my case:
-lcrypt -lm)
C: path to those external libraries (e.g., /usr/local/lib)

On the linker command line, we need this information in one of the
following two orders:

A B C D
A C B D

The Makefile.shlib receives from the respective main makefile "A B D" in
SHLIB_LINK and would have to insert "C" in the middle somewhere.
Currently, the actual behavior is "C A B D" and the failed patch wanted
to do "A B D C", both of which are wrong.

So either we code up some intelligence to put the "C" in the right
position or we have to pass down "A B" and "D" separately from the main
makefile.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2005-07-04 16:00:49 Re: Disable page writes when fsync off, add GUC
Previous Message Pavel Stehule 2005-07-04 15:34:12 Re: User's exception plpgsql

Browse pgsql-patches by date

  From Date Subject
Next Message Peter Eisentraut 2005-07-04 16:00:49 Re: Disable page writes when fsync off, add GUC
Previous Message Pavel Stehule 2005-07-04 15:34:12 Re: User's exception plpgsql