I need help with installing a software.

In general: I try to install PostGIS on a cluster (CentOS) and do not have admin rights. There is a sqlite3 installation (connected to the error), but this seems corrupt. My own one usually works and has (also by install-process) been used previously.

I cannot use yum.

In detail:

For having the MakeFiles build I set flags as I believe to possibly need them:

./configure --prefix="$HOME/.local" CFLAGS="-I$HOME/.local/include" LDFLAGS="-L$HOME/.local/lib" LT_SYS_LIBRARY_PATH="$HOME/.local/lib" LIBS="-L$HOME/.local/lib" SQLITE3_CFLAGS="-I$HOME/.local/include" SQLITE3_LIBS="-L$HOME/.local/lib"

But the following error is thrown when running make:

/usr/bin/sed: can't read /usr/local/lib/libsqlite3.la: No such file or directory

libtool: error: '/usr/local/lib/libsqlite3.la' is not a valid libtool archive

Right after (but I don't see the connection):

libtool: link: ranlib .libs/liblwgeom.a

If I run make again, it jumps that directory. But gets stuck with a similar error (which is not jumped by running make another time):

/bin/sh ../../libtool --mode=link gcc -Wall -Wmissing-prototypes -std=gnu99 -I<exp. $HOME>/.local/include -fno-math-errno -fno-signed-zeros -fPIC -DPIC -I../rt_core -I../../liblwgeom -I<exp. $HOME>/.local/include -I/usr/include/gdal -I<exp. $HOME>/.local/include ../rt_core/librtcore.a raster2pgsql.o -L<exp. $HOME>/.local/lib -static ../../liblwgeom/liblwgeom.la -L/usr/lib64 -lgdal -L<exp. $HOME>/.local/lib -lgeos_c -lc -lm -o raster2pgsql

libtool: error: cannot find the library '/usr/local/lib/libsqlite3.la' or unhandled argument '/usr/local/lib/libsqlite3.la'

I don't get why libtool searches in '/usr/local/lib/'. I didn't find that hardcoded in libtool or the MakeFiles. I'm clueless - and this is above my skill (apperently).

Can you help me?

1 Answer 1


One of the dependencies (proj) linked in its .la file to the malicious sqlite3 version. Reinstalling this dependency solved the issue.

What would help in similar cases would be to search the 'wrong path' in the dependencies:

find <deps lib dir> -type f -exec grep -l "<wrong path>" {} +

Kudos go to https://stackoverflow.com/a/62500481/14339502 who stated the valuable hint that "it seems like you have some other .la file that references it".

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .