I'm trying to install asdmysql-python. When I try to build it I get the following errors:
I got the Mac installer from macpython.org and installed that. But, it has errors in it.
How can I fix this?
Code:
$ python setup.py build
running build
running build_py
copying MySQLdb/release.py -> build/lib.darwin-8.8.0-Power_Macintosh-2.3/MySQLdb
running build_ext
building '_mysql' extension
/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/config/PantherPythonFix/run-gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I/usr/local/mysql/include -I/System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3 -c _mysql.c -o build/temp.darwin-8.8.0-Power_Macintosh-2.3/_mysql.o -Os -arch ppc64 -fno-common -Dversion_info="(1,2,1,'final',2)" -D__version__="1.2.1_p2"
In file included from /System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3/Python.h:48,
from pymemcompat.h:10,
from _mysql.c:29:
/System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3/pyport.h:554:2: error: #error "LONG_BIT definition appears wrong for platform (bad gcc/glibc config?)."
In file included from _mysql.c:40:
/usr/local/mysql/include/my_config.h:1018:1: warning: "SIZEOF_LONG" redefined
In file included from /System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3/Python.h:8,
from pymemcompat.h:10,
from _mysql.c:29:
/System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3/pyconfig.h:726:1: warning: this is the location of the previous definition
error: command '/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/config/PantherPythonFix/run-gcc' failed with exit status 1
I got the Mac installer from macpython.org and installed that. But, it has errors in it.
Code:
>>> import MySQLdb
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "MySQLdb/__init__.py", line 19, in ?
import _mysql
ImportError: No module named _mysql
How can I fix this?