easy_install compile error in OSX 10.5 PPC
MySQL database connector for Python programming
Brought to you by:
adustman
When make "sudo easy_install MySQL-python", gcc for macosx 10.5 PPC throw an error of duplicate declaration.
I solved this error commenting line 92 of "/usr/include/sys/types.h"
$ sudo easy_install MySQL-python
Searching for MySQL-python
Reading http://pypi.python.org/simple/MySQL-python/
Reading http://sourceforge.net/projects/mysql-python
Reading http://sourceforge.net/projects/mysql-python/
Best match: MySQL-python 1.2.2
Downloading http://osdn.dl.sourceforge.net/sourceforge/mysql-python/MySQL-python-1.2.2.tar.gz
Processing MySQL-python-1.2.2.tar.gz
Running MySQL-python-1.2.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-mvd_5X/MySQL-python-1.2.2/egg-dist-tmp-z53AT8
In file included from /usr/local/mysql/include/mysql.h:43,
from _mysql.c:40:
/usr/include/sys/types.h:92: error: duplicate ‘unsigned’
/usr/include/sys/types.h:92: error: two or more data types in declaration specifiers
error: Setup script exited with error: command 'gcc' failed with exit status 1
Line 92: //typedef unsigned int uint; /* Sys V compat */
Logged In: YES
user_id=1416312
Originator: YES
Import error after coorectly compiled.
After compiled editing line 92 in file "/usr/include/sys/types.h", when I import raise ImportError:
The error is caused because path of "/usr/local/mysql/lib/mysql/libmysqlclient_r.15.dylib" is not correct.
The correct directory is "/usr/local/mysql/lib/libmysqlclient_r.15.dylib".
I solved this error creating a symbolic link to same directory.
cd /usr/local/mysql/lib/
sudo ln -s . mysql
Now work succefull
Logged In: YES
user_id=754964
Originator: NO
that's a duplicate bug of #1808476