>pip install MySQL-python
报错误提示:
_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory error: command '"C:\Users\fnngj\AppData\Local\Programs\Common\Microsoft\Visual C ++ for Python\9.0\VC\Bin\amd64\cl.exe"' failed with exit status 2
原因:原因是安装MySQL的时候没有安装C语言库。
解决:重新运行MySQL的安装程序,选择Modify,把“C Include Files / Lib Files”勾选上,并安装。
进入https://www.lfd.uci.edu/~gohlke/pythonlibs/#mysql-python64位下载MySQL_python-1.2.5-cp27-none-win_amd64.whl
在cd到MySQL_python-1.2.5-cp27-none-win_amd64.whl
文件目录
pip install MySQL_python-1.2.5-cp27-none-win_amd64.whl
即可安装完成
网友评论