Re: [GENERAL] Can't Build 7.3.4 on OS X - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [GENERAL] Can't Build 7.3.4 on OS X
Date
Msg-id 20128.1064338128@sss.pgh.pa.us
Whole thread Raw
In response to Re: [GENERAL] Can't Build 7.3.4 on OS X  (Marko Karppinen <karppinen@pobox.com>)
Responses Re: [GENERAL] Can't Build 7.3.4 on OS X
List pgsql-hackers
Marko Karppinen <karppinen@pobox.com> writes:
>> 3.  What's with the WITHOUT_DARWIN_BUNDLE_LOADER hack for ecpg?

> The linker doesn't like symbols that are defined both in the shared 
> object
> that's being linked and the bundle_loader binary. ecpg contains symbols
> that are in the postgresql binary, too, leading to the link failing with
> multiply-defined errors.

> The easiest way for me to fix this -- I don't really know my way around 
> the
> source base -- was to specify by hand that the -bundle-loader flag isn't
> used on these occasions.

I think the right fix is that "-bundle-loader /path/to/postgres" should
be included in the link only for shlibs that are intended to be loaded
into the backend.  Otherwise you are lying to the linker; the mere fact
that it fails to fail doesn't make it the right thing to do.  (As an
example of how it could go wrong, what if there is a real undefined
symbol problem in libpq, but it happens to match some backend symbol?)

We used to have a similar requirement for some other platforms (AIX
I think), and there was a macro named something like BE_SHLIBS to
include the right platform-dependent stuff for such shlibs.  Not sure
what happened to it.  Peter, do you remember that?
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pg_dump doesn't dump binary compatible casts
Next
From: Neil Conway
Date:
Subject: website announcement for 7.4 beta