Prashanth
Prashanth

Reputation: 41

OSError: /usr/lib/libgdal.so.20: undefined symbol: sqlite3_column_table_name

I have followed the tutorial for installing Geodjango on my Ubuntu. I am using Django 1.11.2 and Python 2.7.6, postgres-9.3.2 and postgis 2.0.3.

I have checked here and here, but found no solution.

But after my installation, when I tried to run, I got error: OSError: /usr/lib/libgdal.so.20: undefined symbol: sqlite3_column_table_name

lgdal = CDLL(lib_path)
self._handle = _dlopen(self._name, mode)

Upvotes: 4

Views: 5361

Answers (2)

Nahuel Cabrera
Nahuel Cabrera

Reputation: 346

special thanks > more indifferent

https://blog.csdn.net/qq_38979769/article/details/129723825

download sqlite-autoconf-${current_version}.tar.gz version no amalgamation

tar -xvf sqlite-autoconf-3420000.tar.gz

cd sqlite-autoconf-3420000/

gedit sqlite3.c

edit first macro definitions lines and add define SQLITE_ENABLE_COLUMN_METADATA 1 like this


#ifndef SQLITE_TCLAPI
#  define SQLITE_TCLAPI
#  define SQLITE_ENABLE_COLUMN_METADATA 1
#endif

save and make install

./configure

make

make uninstall

make install

enjoy

if the installation is corrupted retry

sudo apt install qgis qgis-plugin-grass

Upvotes: -1

Ganesh
Ganesh

Reputation: 3474

Try building SQLite from source with

CFLAGS="-DSQLITE_ENABLE_COLUMN_METADATA=1" ./configure
make
sudo make install

I use cutting edge SQLite, built from source, I've faced a similar situation and searched for an answer but nobody answered. Finally, this solved the problem.

Reference - https://www.sqlite.org/compile.html#enable_column_metadata

Upvotes: 3

Related Questions