Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > d3c4bfd951c25dab3d8c83571c73f957 > files > 27

postgresql-8.1.23-10.el5_10.src.rpm

We configure Postgres with --disable-rpath because for the most part we
want to leave it to ldconfig to determine where libraries are.  However,
for some reason the Perl package puts libperl.so in a nonstandard place
and doesn't add that place to the ldconfig search path.  I think this
is a Perl packaging bug, myself, but apparently it's not going to change.
So work around it by adding an rpath spec to plperl.so (only).
Per bug #162198.


diff -Naur postgresql-8.1.21.orig/src/pl/plperl/GNUmakefile postgresql-8.1.21/src/pl/plperl/GNUmakefile
--- postgresql-8.1.21.orig/src/pl/plperl/GNUmakefile	2010-05-13 12:43:40.000000000 -0400
+++ postgresql-8.1.21/src/pl/plperl/GNUmakefile	2010-05-14 12:16:02.000000000 -0400
@@ -36,6 +36,9 @@
 
 SHLIB_LINK = $(perl_embed_ldflags) $(BE_DLLLIBS)
 
+# Force rpath to be used even though we disable it everywhere else
+SHLIB_LINK += $(rpath)
+
 REGRESS_OPTS = --dbname=$(PL_TESTDB) --load-language=plperl --load-language=plperlu
 REGRESS = plperl plperl_trigger plperl_shared plperl_elog
 # if Perl can support two interpreters in one backend,