[postgis-devel] module linking troubles

Sandro Santilli strk at keybit.net
Tue Jun 28 10:08:48 PDT 2011


On Tue, Jun 28, 2011 at 08:58:54AM -0600, Bryce L Nordgren wrote:
> On Mon, Jun 27, 2011 at 1:31 AM, Sandro Santilli <strk at keybit.net> wrote:
> 
> > On Thu, Jun 23, 2011 at 11:21:17PM +0000, Bryce L Nordgren wrote:This is
> > where libtool comes handy, as it abstracts the way you link to
> > libraries under different systems....
> > Anyway, if you go dynamic linking I guess your problem is about "make
> > check" ?
> > Or what is it ?
> >
> >
> Can't even get to make check. The problem is that trying to install the
> raster bits in the database (e.g., running psql -f rtpostgis-2.0.sql
> MyDatabase) causes a "failed to load shared library' error (actual message
> on the ticket.)

Wait a sec.
First of all, "make check" should be done _before_ "make install".
Second: running psql -f rtpostgis-2.0.sql is "enabling" a database,
not installing; the library needs to be installed before enabling 
the database.

That said, I'm not sure you can dynamically link to other libraries
which are not in standard system places (but rather in postgresql
specific dirs) and expect that to work that easily.
There should be two ways:
 1. tell the system to look into the postgresql library dir
 2. encode the postgresql lib dir into the rt library (-rpath)

Or, revert to statically linking liblwgeom, which is what postgis
shared library does.

--strk; 

  ()   Free GIS & Flash consultant/developer
  /\   http://strk.keybit.net/services.html



More information about the postgis-devel mailing list