MySQL_python install failed on Ubuntu 7.1

Bruza benruza at gmail.com
Tue Dec 18 00:47:29 EST 2007


On Dec 17, 1:31 pm, Bruno Desthuilliers
<bdesth.quelquech... at free.quelquepart.fr> wrote:
> Bruza a écrit :
>
> > I installed MySQL 5.0.45 onUbuntu7.1and downloadMySQL_pythonfrom
> > Sourceforge (http://sourceforge.net/project/showfiles.php?
> > group_id=22307). Then I untar the package and executed "python
> > setup.pyinstall". But I got compilation errors (see part of the
> >failedmessages below).
>
> > Looks like the installation tried to compile the _mysql extension and
> >failed. Anybody knows a solution to this problem?
>
> (snip)
>
> > In file included from _mysql.c:29:
> > pymemcompat.h:10:20: error: Python.h: No such file or directory
>
> Looks like gcc doesn't find the Python's headers. You probably need toinstallthe "python-dev" (or whatever it's named onUbuntu) package,
> that is the one with the required stuff to compile and link C libs
> relying on CPython implementation.

Bruno,

I got it working! As you suggested, I did "sudo apt-get install python-
dev", then "sudo apt-get install mysqldb-python", and it's working
now. Thanks,

Bruza



More information about the Python-list mailing list