[Zope-DB] ZMySQLdb

Eron Lloyd elloyd@lancaster.lib.pa.us
Mon, 31 Mar 2003 20:43:56 -0500


Has anyone gotten MySQLdb to build on SuSE 8.1? Seems like something strange 
is going on, as I couldn't get mxODBC to build either. I'm attempting to get 
Zope 2.6.1 connected to MySQL 4.0.12 using either ZMySQLdb or mxODBC. Both 
Zope & MySQL are working fine. Using gcc 3.2, I get screen after screen of 
undeclared variable errors:

building '_mysql' extension
gcc -DNDEBUG -D_FILE_OFFSET_BITS=64 -DHAVE_LARGEFILE_SUPPORT -O2 -march=i586 
-mcpu=i686 -fmessage-length=0 -fPIC -fPIC -I/usr/include/mysql 
-I/usr/local/include/mysql -I/usr/local/mysql/include/mysql 
-I/usr/include/python2.2 -c _mysql.c -o build/temp.linux-i686-2.2/_mysql.o
_mysql.c:41:19: mysql.h: No such file or directory
_mysql.c:42:26: mysqld_error.h: No such file or directory
_mysql.c:43:20: errmsg.h: No such file or directory
_mysql.c:73: parse error before "MYSQL"
...
_mysql.c: At top level:
_mysql.c:1859: parse error before '*' token
_mysql.c: In function `_mysql_ResultObject_getattr':
_mysql.c:1864: `self' undeclared (first use in this function)
_mysql.c:1864: `name' undeclared (first use in this function)
...

It looks like something in the build process isn't being seen (mysql headers), 
but I'm no C expert. MySQL is located in /usr/local/mysql.

Thanks for any help,

Eron