installing "pysqlite"

Paul Boddie paul at
Thu Mar 1 11:46:37 CET 2007

On 1 Mar, 10:34, "Nader" <n.em... at> wrote:
> I have expanded the LD_LIBRARY_PATH to my home lib (export
> LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/usr/people/emami/lib).
> I have built and installed the 'pysqlite-2.3.3' with the next
> 'setup.cfg' :
> [build_ext]
> define=
> include_dirs=/usr/people/emami/include
> library_dirs=/usr/people/emami/lib
> #libraries=/usr/people/emami/lib/  (this line as a
> comment)

This looks alright. Be sure to verify that is in /usr/
people/emami/lib, although I suppose you've done this, looking at your

> The resutl of this process was:
> running install_lib
> copying build/lib.linux-i686-2.4/pysqlite2/ -> /usr/people/
> emami/lib/python2.4/site-packages/pysqlite2
> running install_data
> This message had given after installing. I have controll the '/usr/
> people/emami/lib/python2.4/site-packages/pysqlite2' whether the
> '' has copied there. Yes it has. Okay!

So pysqlite2 has installed properly at least.

> I go to python and I give the next command:
> >>> from pysqlite import test
> and Unfortunately I get the next error message:


> ImportError: /usr/people/emami/lib/python2.4/site-packages/pysqlite2/
> undefined symbol: sqlite3_set_authorizer

I'm running out of ideas here, but you could try doing this:

ldd /usr/people/emami/lib/python2.4/site-packages/pysqlite2/

This should show a list of references to libraries, but if one of them
is missing in some way then it means that it isn't found by the linker
and it's not on the LD_LIBRARY_PATH. Another thought is that
sqlite3_set_authorizer isn't found in the SQLite library - you can
test this by doing the following:

nm /usr/people/emami/lib/

I get something like this in response:

00000000000110b0 T sqlite3_set_authorizer

If you don't get anything in response or if you see "U" instead of
"T", then this might indicate an problem with the way SQLite has been

> Do you know what option I have to give to if I want to use the
> 'easy_install" tool?
> %easy_install pysqlite (with some optione with which it cab find the
> installed '')

I'm no easy_install expert, I'm afraid. You might want to talk to the
pysqlite people directly if what I've suggested doesn't help you


More information about the Python-list mailing list