Skip site navigation (1) Skip section navigation (2)

9.2 won't load C-language function

From: Craig James <cjames(at)emolecules(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: 9.2 won't load C-language function
Date: 2012-10-10 18:22:17
Message-ID: CAFwQ8reTRHRgfhwQ-yQ+121JBwg67fEwQb677A_-j1CJQCztoA@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-admin
I have a C-language function I've been using on 8.4 for a long time.  On
9.2 it won't load:

test=# set search_path = public;
SET
test=# CREATE OR REPLACE FUNCTION chmoogle_session_id() RETURNS integer
AS '/usr/local/pgsql/lib/libchmoogle.so', 'chmoogle_session_id'
LANGUAGE c VOLATILE;
ERROR:  could not load library "/usr/local/pgsql/lib/libchmoogle.so":
libopenbabel.so.4: cannot open shared object file: No such file or directory

But libopenbabel.so.4 does exist:

# ls -l /usr/local/pgsql/lib/libopenbabel.so.4
-rwxr-xr-x 1 root root 18250709 2012-10-09 18:05
/usr/local/pgsql/lib/libopenbabel.so.4*

There seems to be some difference in the library search path from 8.4 to
9.2.  For administrative simplicity, I don't use ldconfig, besides which it
wasn't needed for 8.4.

What changed in how libraries are loaded between 8.4 and 9.2?

Thanks,
Craig

Responses

pgsql-admin by date

Next:From: Tom LaneDate: 2012-10-10 21:11:07
Subject: Re: 9.2 won't load C-language function
Previous:From: Dave PooserDate: 2012-10-10 17:41:10
Subject: Multiple LDAP servers -- no failover?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group