Apparent gcc error when building pysqlite
Dear all,
I'm something of a n00b, so please be gentle.
I'm running Ubuntu 8.04
I've got sqlite3 installed, but I keep getting errors when trying trying to install pysqlite (2.4.1 or 2.5.1).
If I run
$ python setup.py build
things look like they're going ok for a while, but then I soon start getting errors:
running build
running build_py
running build_ext
building 'pysqlite2._sqlite' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DMODULE_NAME="pysqlite2.dbapi2" -I/usr/local/include /usr/bin -I/usr/include/python2.5 -c src/module.c -o build/temp.linux-i686-2.5/src/module.o
In file included from src/module.c:24:
src/connection.h:26:20: error: Python.h: No such file or directory
[snip]
There's a whole load more stuff, ending up with:
src/module.c:303: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘init_sqlite’
error: command 'gcc' failed with exit status 1
gcc -v tells me that gcc exists so I think that last error must be a red herring. However, after searching the web and trying lots of things, I've not managed to build pysqlite.
In case it's relevant, setup.cfg contains the following (after attempts at various things having tried following up on some suggestions I found posted elsewhere):
[build_ext]
#define=
#include_dirs=/usr/local/include
#library_dirs=/usr/local/lib
libraries=sqlite3
I'd be very grateful to anyone who has any suggestions. Again, I'm a newbie so please keep that in mind.
Many thanks,
TolstoyTheCat
|