当我尝试安装sql时,我与microsoft visual studio发生冲突。请派人来帮忙。我用简易安装安装它,我也尝试了其他5个替代命令,但我不断得到与visual studio冲突,无法找到它在添加或删除程序(2015)版本。我还安装了连接器
$ easy_install mysql-python
Searching for mysql-python
Reading https://pypi.org/simple/mysql-python/
Downloading https://files.pythonhosted.org/packages/a5/e9/51b544da85a36a68debe7a7091f068d802fc515a3a202652828c73453cad/MySQL-python-1.2.5.zip#sha256=811040b647e5d5686f84db415efd697e6250008b112b6909ba77ac059e140c74
Best match: MySQL-python 1.2.5
Processing MySQL-python-1.2.5.zip
Writing C:\Users\Suhasm\AppData\Local\Temp\easy_install-uciw2yjf\MySQL-python-1.2.5\setup.cfg
Running MySQL-python-1.2.5\setup.py -q bdist_egg --dist-dir C:\Users\Suhasm\AppData\Local\Temp\easy_install-uciw2yjf\MySQL-python-1.2.5\egg-dist-tmp-4jbv49w6
_mysql.c
C:\Program Files (x86)\MySQL\MySQL Connector C 6.0.2\include\config-win.h(192): warning C4005: 'isnan': macro redefinition
C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\ucrt\corecrt_math.h(275): note: see previous definition of 'isnan'
C:\Program Files (x86)\MySQL\MySQL Connector C 6.0.2\include\config-win.h(203): warning C4005: 'SIZEOF_OFF_T': macro redefinition
c:\users\suhasm\appdata\local\programs\python\python36-32\include\pyconfig.h(324): note: see previous definition of 'SIZEOF_OFF_T'
C:\Program Files (x86)\MySQL\MySQL Connector C 6.0.2\include\config-win.h(301): warning C4005: 'HAVE_STDDEF_H': macro redefinition
c:\users\suhasm\appdata\local\programs\python\python36-32\include\pyconfig.h(602): note: see previous definition of 'HAVE_STDDEF_H'
_mysql.c(297): warning C4090: '=': different 'const' qualifiers
_mysql.c(327): warning C4090: '=': different 'const' qualifiers
_mysql.c(623): warning C4090: '=': different 'const' qualifiers
_mysql.c(624): warning C4090: '=': different 'const' qualifiers
_mysql.c(625): warning C4090: '=': different 'const' qualifiers
_mysql.c(626): warning C4090: '=': different 'const' qualifiers
_mysql.c(627): warning C4090: '=': different 'const' qualifiers
_mysql.c(1118): warning C4090: '=': different 'const' qualifiers
_mysql.c(1161): warning C4090: '=': different 'const' qualifiers
_mysql.c(1165): warning C4090: '=': different 'const' qualifiers
_mysql.c(1532): warning C4018: '<': signed/unsigned mismatch
Creating library build\temp.win32-3.6\Release\_mysql.cp36-win32.lib and object build\temp.win32-3.6\Release\_mysql.cp36-win32.exp
mysqlclient.lib(typelib.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(viosslfactories.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(my_winfile.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(my_messnc.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(client.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(my_thr_init.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(my_init.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(default.obj) : error LNK2001: unresolved external symbol ___iob_func
mysqlclient.lib(default.obj) : error LNK2001: unresolved external symbol _printf
build\lib.win32-3.6\_mysql.cp36-win32.pyd : fatal error LNK1120: 2 unresolved externals
error: Setup script exited with error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1120
2条答案
按热度按时间oalqel3c1#
是的,我通过下载二进制文件解决了这个问题
fnatzsnv2#
你试过pip安装mysqlclient吗?