dbTalk Databases Forums  

[BUGS] 8.0.0beta3: dblink can't find libpq

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] 8.0.0beta3: dblink can't find libpq in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Michael Fuhr
 
Posts: n/a

Default [BUGS] 8.0.0beta3: dblink can't find libpq - 10-09-2004 , 09:22 PM






PostgreSQL 8.0.0beta3 (CVS)
Solaris 9
gcc 3.4.2
gmake 3.80

Attempting to install contrib/dblink fails due to libpq not being
found:

% psql -Upostgres test < dblink.sql
ERROR: could not load library "/usr/local/pgsql/lib/dblink.so": ld.so.1: /usr/local/pgsql/bin/postgres: fatal: libpq.so.3: open failed: No such file or directory

This happens if libpq.so.3 isn't in a directory that the run-time
linker is configured to search. The standard client applications
work because they were linked with "-R/usr/local/pgsql/lib", which
is this platform's way of adding library search directories to a
dynamically-linked object (other systems may use a different set
of options).

I got dblink to work by editing contrib/dblink/Makefile and changing
this line:

SHLIB_LINK = $(libpq)

to this:

SHLIB_LINK = -R/usr/local/pgsql/lib $(libpq)

I don't know what the correct platform-independent incantation
should be -- I tried using $(rpath) but it didn't expand to
anything.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Reply With Quote
  #2  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] 8.0.0beta3: dblink can't find libpq - 10-10-2004 , 11:07 AM






Michael Fuhr <mike (AT) fuhr (DOT) org> writes:
Quote:
PostgreSQL 8.0.0beta3 (CVS)
Solaris 9

I don't know what the correct platform-independent incantation
should be -- I tried using $(rpath) but it didn't expand to
anything.
Why not? Makefile.solaris certainly looks like it will set rpath
to what you want.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo (AT) postgresql (DOT) org)


Reply With Quote
  #3  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] 8.0.0beta3: dblink can't find libpq - 10-10-2004 , 11:17 AM



Michael Fuhr <mike (AT) fuhr (DOT) org> writes:
Quote:
I got dblink to work by editing contrib/dblink/Makefile and changing
this line:
SHLIB_LINK = $(libpq)
Actually it appears the true culprit is over here:

RCS file: /cvsroot/pgsql-server/src/makefiles/pgxs.mk,v
retrieving revision 1.2
diff -c -r1.2 pgxs.mk
*** pgxs.mk 6 Oct 2004 08:50:02 -0000 1.2
--- pgxs.mk 10 Oct 2004 16:12:31 -0000
***************
*** 77,83 ****
NAME = $(MODULE_big)
SO_MAJOR_VERSION= 0
SO_MINOR_VERSION= 0
- rpath =

SHLIB_LINK += $(BE_DLLLIBS)

--- 77,82 ----

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo (AT) postgresql (DOT) org


Reply With Quote
  #4  
Old   
Michael Fuhr
 
Posts: n/a

Default Re: [BUGS] 8.0.0beta3: dblink can't find libpq - 10-10-2004 , 05:54 PM



On Sun, Oct 10, 2004 at 12:16:14PM -0400, Tom Lane wrote:
Quote:
Actually it appears the true culprit is over here:

RCS file: /cvsroot/pgsql-server/src/makefiles/pgxs.mk,v
Works now -- thanks.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.