<br><br><div class="gmail_quote">On Wed, Jun 29, 2011 at 2:13 PM, Sandro Santilli <span dir="ltr"><<a href="mailto:strk@keybit.net">strk@keybit.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
The ERROR you printed above suggests<br>
your added linking is performed trough an -rpath switch or something similar<br>
encoding the builddir path into the <a href="http://rtpostgis-2.0.so" target="_blank">rtpostgis-2.0.so</a> file. You should either<br>
not do that and let the system know where to find <a href="http://postgis-2.0.so" target="_blank">postgis-2.0.so</a> OR you should<br>
set that path to be the installation path, rather than the build path.<br>
<br>
Note that using an -rpath makes it harder (if possible at all) to run the<br>
regress testing using the just-built postgis library rather than the system<br>
installed one...<br></blockquote><div><br>The linking line in question is: <br><br>gcc -march=x86-64 -mtune=generic -O2 -pipe -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fwrapv -fpic -shared -o <a href="http://rtpostgis-2.0.so">rtpostgis-2.0.so</a> rt_pg.o -L/usr/lib -Wl,--hash-style=gnu -Wl,--as-needed  -Wl,--as-needed -Wl,-rpath,'/usr/lib',--enable-new-dtags  -L/usr/lib  -lgeos_c -lproj -lxml2 -lz -lm ../rt_core/librtcore.a /home/bnordgren/build/local/postgis-svn/src/trunk-build/liblwgeom/liblwgeom.a -Wl,-rpath-link,/home/bnordgren/build/local/postgis-svn/src/trunk-build/postgis -L/home/bnordgren/build/local/postgis-svn/src/trunk-build/postgis -l:<a href="http://postgis-2.0.so">postgis-2.0.so</a> -L/usr/lib -lgdal<br>
<br>This is actually the third iteration, and the first two tries had no -rpath-link. The "-rpath=/usr/lib" was actually supplied by pg_config and I don't think I can get rid of it without seriously messing with the build system. I doubt that's my problem anyway, since that's actually where I want it to look.<br>
<br>On my first try, I rather simplistically listed the path to the <a href="http://postgis-2.0.so">postgis-2.0.so</a> file with no special command line options at all. Everything I've tried seems to remember where <a href="http://postgis-2.0.so">postgis-2.0.so</a> was at the time it was linked. <br>
</div></div>