title: Python: How to install mysqldb on windows 7 x64?
body: <p>Im trying install <strong>Mysql-python</strong> on <strong>windows x64</strong>.</p>
  
  <p>I installed <strong>python x64</strong>, <strong>setuptools</strong> (checked on the <strong>leaf</strong> lib, successfully installed) but i can't install <strong>mysqldb</strong>.
  I trying to execute </p>
  
  <blockquote>
    <p>C:\Users\Fedcomp\Desktop\leaf-0.4\MySQL-python-1.2.3>python
    setup.py install</p>
  </blockquote>
  
  <p>but catch this</p>
  
  <pre><code>In file included from _mysql.c:34:
  D:\servers\xampp_server\xampp\mysql\include/config-win.h:211:1: warning: "finite
  " redefined
  D:\servers\xampp_server\xampp\mysql\include/config-win.h:164:1: warning: this is
   the location of the previous definition
  D:\servers\xampp_server\xampp\mysql\include/config-win.h:277:1: warning: "HAVE_S
  TDDEF_H" redefined
  In file included from D:\Python27\include/Python.h:8,
                   from pymemcompat.h:10,
                   from _mysql.c:29:
  D:\Python27\include/pyconfig.h:673:1: warning: this is the location of the previ
  ous definition
  error: command 'gcc' failed with exit status 1
  </code></pre>
  
  <p>also trying with msvc but catch this (MS Visual express installed)</p>
  
  <pre><code>C:\Users\Fedcomp\Desktop\leaf-0.4\MySQL-python-1.2.3&gt;python setup.py install bui
  ld --compiler=msvc
  running install
  running bdist_egg
  running egg_info
  writing MySQL_python.egg-info\PKG-INFO
  writing top-level names to MySQL_python.egg-info\top_level.txt
  writing dependency_links to MySQL_python.egg-info\dependency_links.txt
  reading manifest file 'MySQL_python.egg-info\SOURCES.txt'
  reading manifest template 'MANIFEST.in'
  warning: no files found matching 'MANIFEST'
  warning: no files found matching 'ChangeLog'
  warning: no files found matching 'GPL'
  writing manifest file 'MySQL_python.egg-info\SOURCES.txt'
  installing library code to build\bdist.win-amd64\egg
  running install_lib
  running build_py
  copying MySQLdb\release.py -&gt; build\lib.win-amd64-2.7\MySQLdb
  running build_ext
  building '_mysql' extension
  error: Unable to find vcvarsall.bat
  </code></pre>
  
  <p><strong>How to install mysqldb correctly on windows x64?</strong>
  <em>(headers from original mysql installation because, in xampp server they doesn't exist)</em></p>
  
  <p>Or may someone compile <strong>mysqldb</strong> for windows <strong>python x64</strong> or <strong>python x86</strong>?</p>