win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
今天想在在win7 64位环境下使用python 操作mysql
在安装MySQL-python 时报错:
_mysql.c
_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No s uch 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
----------------------------------------
Cleaning up... Command C:\Python27\python.exe -c "import setuptools, tokenize;__file__='c:\\use rs\\fnngj\\appdata\\local\\temp\\pip_build_fnngj\\MySQL-python\\setup.py';exec(c ompile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), _ _file__, 'exec'))" install --record c:\users\fnngj\appdata\local\temp\pip-peervp -record\install-record.txt --single-version-externally-managed --compile failed with error code 1 in c:\users\fnngj\appdata\local\temp\pip_build_fnngj\MySQL-pyt hon Storing debug log for failure in C:\Users\fnngj\pip\pip.log
太奇怪了,以前是在ubuntu/deepin 系统可以安装。换成win7 64位就不行了。
按理说win7都出来这么多年了,python也更新的这么猛的语言,怎么链接mysql就不行了。
百度了半天,找到了以下答案:
----------------------------------------------
1)问题:_mysql.c(34) : fatal error C1083: Cannot open include file: ‘config-win.h’: No such file or directory error: command ‘”C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe”‘ failed with exitstatus 2
原因:原因是安装MySQL的时候没有安装C语言库。
解决:重新运行MySQL的安装程序,选择Modify,把“C Include Files / Lib Files”勾选上,并安装。
---------------------------------------------
百度来百度去,就这么一个答案,都是复制粘贴的。害我反复把mysql装了几遍,跟本他妈的没找到“C Include Files / Lib Files” 选项在哪儿? 也许是mysql新版本没这选项了。
最后不得不FQ出去看看了。
原来还是驱动问题,关人家mysql啥事儿!
安装:MySQL-python-1.2.3.win-amd64-py2.7.exe 就可以了(百度csdn下载可以找到)
我的驱动是从这儿下的,不行!
https://pypi.python.org/pypi/MySQL-python/
也用 pip 装了,不行!
C:\Python27\Scripts>pip install MySQL-python
这pip居然检测不出我的系统版本。 还有为啥python官网搜索不到这个 64位的驱动,我也是醉了。
----
希望这个问题被百度收录,遇到这个问题的人,别在被上面的答案忽悠了,真不管人家mysql的事儿。
win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory的更多相关文章
- (转)win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
原文地址:http://www.cnblogs.com/fnng/p/4115607.html 作者:虫师 今天想在在win7 64位环境下使用python 操作mysql 在安装MySQL-pyth ...
- _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决 mysql安装python
在win7下安装了Python后,想安装python-MySQL,使用pip安装出现如下问题: >pip install MySQL-python _mysql.c(42) : fatal er ...
- (Python mysql驱动的解决)_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决
在win7下安装了Python后,想安装python-MySQL,使用pip安装出现如下问题: >pip install MySQL-python _mysql.c(42) : fatal er ...
- Python 安装MySQLdb模块遇到报错及解决方案:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
一.问题 系统:win7 64位 在下载MySQL-python-1.2.5.zip,使用python setup.py install 安装时,出现以下报错: _mysql.c(42) : fata ...
- _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决
在win7下安装了python后,想安装python-mysql,使用pip安装出现如下问题: >pip install MySQL-python _mysql.c(42) : fatal er ...
- 安装MySQL-python报错:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory或者 build\lib.win-amd64-2.7\_mysql.pyd : fatal error LNK1120: 56 unresolved externa
解决办法1: 直接下载MySQL-python-1.2.5.win-amd64/32-py2.7.exe,点击安装 此处要注意自己安装的Python和MySQL版本是64位还是32位,否则在进行安装M ...
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
安装mysql-python之前, 请先安装setuptools. https://pypi.python.org/pypi/setuptools/7.0 下载mysql-python. 下载源码包. ...
- [Python]mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
需要安装mysql connector 前往 https://dev.mysql.com/downloads/connector/python/ 下载 选择Platform independence, ...
- win7 VC6.0 安装 fatal error C1083: Cannot open include file: 'Iphlpapi.h': No such file or directory
解决方法: 第一步 安装SDK 第二步 将包含的api放在第一项
随机推荐
- [UML]UML系列——类图class的关联关系(聚合、组合)
关联的概念 关联用来表示两个或多个类的对象之间的结构关系,它在代码中表现为一个类以属性的形式包含对另一个类的一个或多个对象的应用. 程序演示:关联关系(code/assocation) 假设:一个公司 ...
- SHLVL 和 BASH_SUBSHELL 两个变量的区别
SHLVL 是记录多个 Bash 进程实例嵌套深度的累加器,而 BASH_SUBSHELL 是记录一个 Bash 进程实例中多个子 Shell(subshell)嵌套深度的累加器. 看不懂上面这句话不 ...
- table td 文字超出显示省略号
.autocut { width:250px; overflow:hidden; white-space:nowrap; text-overflow:ellip ...
- java基础 作业(一)
题目: 跳水比赛,8个评委打分.运动员的成绩是8个成绩去掉一个最高分,去掉一个最低分,剩下的6个分数 的平均分就是最后 得分.使用以为数组实现打分功能 .请把打分最高的评委和最低的评委找出来. 解析: ...
- Uva 2034
求定积分 (结果当时我没看到平均值) //正常多项式求 #include<iostream> #include<cstdio> #include<cmath> us ...
- TCP/IP四层模型
转自:http://www.cnblogs.com/BlueTzar/articles/811160.html ISO制定的OSI参考模型的过于庞大.复杂招致了许多批评.与此对照,由技术人员自己开发的 ...
- 安装第三方模块方法和requests
如何安装第三方模块 pip3 pip3 install xxxx 源码 下载,解压 进入目录 python setup.py inst ...
- Mybatis在insert操作时返回主键
今天在写项目的时候,遇到一个需求,就是在像数据库插入数据的时候,要保留插入数据的主键,以便后续进行级联时,可以将该主键作为另张表的外键. 但是在正常情况下我们使用插入语句返回的是int型,含义是影响该 ...
- mongodb的查询语句学习摘要
看了些资料,对应只需要知道怎么查询和使用mongodb的我来说,这些足够啦. 左边是mongodb查询语句,右边是sql语句.对照着用,挺方便. db.users.find() select * fr ...
- Xcode 此证书签发者无效
1.https://developer.apple.com/certificationauthority/AppleWWDRCA.cer 安装此证书 2.在keychains里选择login,然后点选 ...