MySQL-Python on OS X

Craig Amundsen amundsen463 at yahoo.com
Tue Sep 9 13:53:22 EDT 2003


Hi -

I'm trying to build the MySQL-Python 0.9.2 module on OS X 10.2.6. I
have installed the Fink version off MySQL (3.23.56-1) and the Fink
version of Python (2.2.2).

I have made the recommended changes to setup.py; I changed the
mysqlclient = thread_safe_library and "mysqlclient_r" or "mysqlclient"
line to
mysqlclient = thread_safe_library and "mysqlclient"

I changed thread_safe_library from YES to NO.

In the darwin section I changed 
include_dirs.append('/sw/include')
library_dirs.append('/sw/lib')
to
include_dirs.append('/sw/include/mysql')
library_dirs.append('/sw/lib/mysql')

When I run 
python setup.py build
I get this error:
line 1033, in gen_lib_options
  File "/sw/lib/python2.2/posixpath.py", line 65, in split
    i = p.rfind('/') + 1
AttributeError: 'int' object has no attribute 'rfind'

It looks to me like p is supposed to be a string containing a path,
but is instead an int. I have not in all my searching, found any
mention of this build error. Does anyone have any hints on how to
resolve this issue?

TIA,
- Craig




More information about the Python-list mailing list