Re: Relocatable installs

From: Jan Wieck <JanWieck(at)Yahoo(dot)com>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Relocatable installs
Date: 2004-05-18 20:56:22
Message-ID: 40AA7876.7000704@Yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian wrote:

> Peter Eisentraut wrote:
>> Bruce Momjian wrote:
>> > We already have --disable-rpath. Seems we would just need something
>> > to use the *.a files.
>>
>> I think it is perfectly sufficient to say that if you want a relocatable
>> install, don't use rpath. Static linking will lead to all other kinds
>> of madness.
>
> OK, but if we don't use rpath, don't we have to do the ld.so.conf or
> environment varaible usage so we can find our shared library. I assume
> the big problem with rpath is that it might find the wrong version of
> our library, right? Is there another downside to it being set?
>

Exactly.

Suppose you have one of these silly RPM based Linux systems. One has to
install PostgreSQL from RPM's in order to satisfy all the dependencies
for whatever else you want. Now you want to install a relocatable
version of PostgreSQL somewhere else, because you don't want to mess up
the RPM installed one.

For sure the ld.so.conf is setup to find the RPM installed version of
libpq. That's why we use rpath, so that you can install PG somewhere
else and the /usr/local/pg75/bin/psql will find the libpq in
/usr/local/pg75/lib instead of /usr/lib. But that's currently a
configure time option and removing rpath altogether will let everything
find the old libpq.

Jan

--
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Gaetano Mendola 2004-05-18 21:25:19 Re: Why new features only in magior releases ?
Previous Message Jan Wieck 2004-05-18 20:49:34 Re: Relocatable installs