Re: LD_LIBRARY_PATH versus rpath - Mailing list pgsql-hackers

From Tom Lane
Subject Re: LD_LIBRARY_PATH versus rpath
Date
Msg-id 15250.1273153122@sss.pgh.pa.us
Whole thread Raw
In response to Re: LD_LIBRARY_PATH versus rpath  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: LD_LIBRARY_PATH versus rpath
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> Greg Stark wrote
>> We only set RPATH if the install location isn't part of the default ld
>> library path specified by /etc/ld.so.conf right? Setting it if it is
>> in the default path would be antisocial.

> How are we going to know at build time what is in the ld.soconf of the 
> installation machine?

Exactly.  In practice, it's on the packager's head to specify
--disable-rpath if he intends to install into the platform's
regular library search path.

Funny point here: in the Fedora/RHEL RPMs, I use --disable-rpath
because "don't use RPATH" is part of the standard packaging guidelines
for that platform.  However, pl/perl has to double back and use rpath
anyway because libperl.so doesn't exist in the ldconfig path; it's in
some version-numbered directory and they don't provide any link or
ldconfig entry so you could find it otherwise.  Annoying as heck.
I've always wondered how many other packagers have to carry patches
similar to
http://cvs.fedoraproject.org/viewvc/rpms/postgresql/devel/postgresql-perl-rpath.patch
        regards, tom lane


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: pg_migrator to /contrib in a later 9.0 beta
Next
From: Joel Jacobson
Date:
Subject: pg_stat_transaction patch