mac安装mysql-python报错

小静龙 发布于 2017/05/28 08:44
阅读 1K+
收藏 0

【开源中国 APP 全新上线】“动弹” 回归、集成大模型对话、畅读技术报告”

使用命令  sudo  pip install mysql-python  安装mysql-python 时报错

Collecting mysql-python

  Downloading MySQL-python-1.2.5.zip (108kB)

    100% |████████████████████████████████| 112kB 736kB/s 

    Complete output from command python setup.py egg_info:

    Traceback (most recent call last):

      File "<string>", line 1, in <module>

      File "/private/tmp/pip-build-kxDfNm/mysql-python/setup.py", line 17, in <module>

        metadata, options = get_config()

      File "setup_posix.py", line 53, in get_config

        libraries = [ dequote(i[2:]) for i in libs if i.startswith(compiler_flag("l")) ]

      File "setup_posix.py", line 8, in dequote

        if s[0] in "\"'" and s[0] == s[-1]:

    IndexError: string index out of range

    

    ----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /private/tmp/pip-build-kxDfNm/mysql-python/

加载中
0
ddzhang
ddzhang

我也遇到了相同的问题,请问你解决了吗?

 

小静龙
小静龙
回复 @ddzhang : 解决了 先装一下brew 然后brew install mysql 然后就可以了
OSCHINA
登录后可查看更多优质内容
返回顶部
顶部