[pysqlite] installing pysqlite2.3 to work with libsqlite3.2 when libsqlite2.8 is also installed

Muhammad Ali talk2ali at gmail.com
Thu May 17 18:38:52 CEST 2007


Hi,

I have libsqlite 2.8.17 installed on my system as well as
libsqlite3.2.8 in different locations. I am using ubuntu 6.06 dapper
and cannot uninstall libsqlite2.8.17 because it is linked with the
desktop system.

When I install pysqlite-2.3.3 it somehow references the older version
of libsqlite, resulting in the following traceback when I try to do
'from pysqlite2 import dbapi2' in python:
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "/usr/lib/python2.4/site-packages/pysqlite2/dbapi2.py", line 27, in ?
    from pysqlite2._sqlite import *
ImportError: /usr/lib/python2.4/site-packages/pysqlite2/_sqlite.so:
undefined symbol: sqlite3_enable_shared_cache

I have searched the mailing lists for this error and realize it can be
fixed by setting my LD_LIBRARY_PATH variable to /usr/local/lib.
Unfortunately, this is not a valid option for me since that messes up
the path for other packages that I need to import (namely matplotlib
i.e. import pylab).

I would like to have an installation of pysqlite that references the
latest version of libsqlite on my system, but I don't know how to go
about doing that. I tried editing setup.cfg in the pysqlite setup
directory and changing the default paths:
include_dirs=/usr/include
library_dirs=/usr/lib
to
include_dirs=/usr/local/include
library_dirs=/usr/local/lib
and doing a re-install (after a 'python setup.py clean -a') in hope of
getting it to work, but it doesn't.

Any help would be greatly appreciated.

Thanks,
Ali.


More information about the pysqlite mailing list