(EXT) Win7 64 installation mysql-python:_mysql.c: Fatal error C1083:cannot open include file: ' Config-win.h ': No such file or dire Ctory

Source: Internet
Author: User

Original address: http://www.cnblogs.com/fnng/p/4115607.html

Insect Master

Today I want to use Python to operate MySQL in the Win7 64-bit environment

In the installation Mysql-python times wrong:

_mysql.c

_MYSQL.C: 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 (' \ 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

It was so strange that it was before the Ubuntu/deepin system could be installed. Change to Win7 64 bit will not be.

Supposedly win7 have been out for so many years, Python also updated so fierce language, how to link MySQL is not.

Baidu took half a day to find the following answers:

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

1) Problem : _mysql.c: 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

cause : The C language Library was not installed when MySQL was installed.

workaround : Re-run the MySQL installer, select Modify, check "C Include files/lib Files" and install.

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

Baidu to Baidu, on such an answer, are copied and pasted. I've been loading MySQL over and over again, and I can't fucking find the "C Include files/lib Files" option? Perhaps the new version of MySQL does not have this option.

Finally had to fq out to see.

Turns out to be the driving problem, shut the others mysql what thing!

Installation: Mysql-python-1.2.3.win-amd64-py2.7.exe on it (Baidu csdn download can be found)

My driver is from here, no!

https://pypi.python.org/pypi/MySQL-python/

Also with PIP installed, no!

C:\python27\scripts>pip Install Mysql-python

This pip actually does not detect my system version. And why the Python official website does not search for this 64-bit driver, I am also drunk.

----

Hope this problem is included in Baidu, meet this problem of people, do not be above the answer is fooled, really no matter what the others MySQL.

Win7 64 installation mysql-python:_mysql.c: Fatal error C1083:cannot open include file: ' Config-win.h ': No such file or Directo Ry

(EXT) Win7 64 installation mysql-python:_mysql.c: Fatal error C1083:cannot open include file: ' Config-win.h ': No such file or dire Ctory

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.