I am running OSX 10.4.9 on a "Santa Rose" Macbook Pro
Python Version: 2.5 (r25:51918)
MySql Version: 5.0.41
MySQLdb Version: 1.2.2
Now the problem I am running into seem similar to the one that was
causing a MySQL with ruby on rails. The problem was rails not being
able to find where the new install had put MySQL's
libmysqlclient_r.dylib.
Here is the print out I am getting:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Frameworks/Python.framework/Versions/2.5/lib/
python2.5/site-packages/PIL/__init__.py", line 19, in <module>
File "build/bdist.macosx-10.3-fat/egg/_mysql.py", line 7, in
<module>
File "build/bdist.macosx-10.3-fat/egg/_mysql.py", line 6, in
__bootstrap__
ImportError: dlopen(/Users/silhyon/.python-eggs/MySQL_python-1.2.2-
py2.5-macosx-10.3-fat.egg-tmp/_mysql.so, 2): Library not loaded: /usr/
local/mysql/lib/mysql/libmysqlclient_r.15.dylib
Referenced from: /Users/silhyon/.python-eggs/MySQL_python-1.2.2-
py2.5-macosx-10.3-fat.egg-tmp/_mysql.so
Reason: image not found
I am unsure of how to fix this problem and googling has got me
nothing. Any help would be appreciated on this matter. Also I am
fairly new to Django and Python itself but am ok with using the
terminal and with terminal commands.
Thanks to all answers in advance
Check out this page:
http://www.agapow.net/programming/python/installing-mysqldb
Towards the bottom of his post you will see a bit about "Later News"
where he describes a problem similar to yours.
The fix for me was to "delete the mySQLdb egg and delete the line
referring to it in the easy-install.pth file." and then reinstall
MySQLdb using the Mac Binary Package instead of from the tarball.
Hopefully this will work for you as well,
-Stephen
-Silhyon