pip 安装 MySQL-python 报错

报错一:EnvironmentError: mysql_config not found

解决:yum install mysql-devel

 

报错二:Python.h No such file or directory

更多的错误见以下几行:

_mysql.c:29:20: fatal error: Python.h: No such file or directory
#include "Python.h"
^
compilation terminated.
error: command 'gcc' failed with exit status 1

 

解决: yum install python-devel.x86_64

 

其实这两个错误是一个,都是没有装python-devel,只不过错误二是64位

posted @ 2017-11-29 18:20  aaron_agu  阅读(2437)  评论(0编辑  收藏  举报