Mac上的pyodbc安装问题

时间:2014-04-22 02:39:17

标签: python sql macos pyodbc

我试图在我的mac上安装pyodbc,因为我想连接到一个sql server而且我已经经历了很多论坛才能让它运行起来。一切都已安装,除了pyodbc(我已尝试过pip,自制软件,easy_istall甚至尝试使用源代码进行安装但没有任何效果)并且它给了我以下错误:


(hhl)OSFOLA-034901:bin henry.humadi$ easy_install pyodbc
Searching for pyodbc
Reading https://pypi.python.org/simple/pyodbc/
Reading http://code.google.com/p/pyodbc
Reading http://code.google.com/p/pyodbc/downloads/list
Best match: pyodbc 3.0.7
Downloading http://pyodbc.googlecode.com/files/pyodbc-3.0.7.zip
Processing pyodbc-3.0.7.zip
Writing /var/folders/w4/h0nc35117x1c0psqpsm4vvlnhk02nh/T/easy_install-AFM6yU/pyodbc-3.0.7/setup.cfg
Running pyodbc-3.0.7/setup.py -q bdist_egg --dist-dir /var/folders/w4/h0nc35117x1c0psqpsm4vvlnhk02nh/T/easy_install-AFM6yU/pyodbc-3.0.7/egg-dist-tmp-G6Yp3F
warning: no files found matching 'tests/*'
clang: error: unknown argument: '-mno-fused-madd' [-Wunused-command-line-argument-hard-error-in-future]
clang: note: this will be a hard error (cannot be downgraded to a warning) in the future
error: Setup script exited with error: command 'cc' failed with exit status 1

任何人都可以请我解读此错误消息。我读过它与Xcode 5.1有关的地方,但我还是不了解它。

提前谢谢。

1 个答案:

答案 0 :(得分:1)

Xcode 5在遇到命令行标志时导致clang抛出致命错误,这打破了很多事情。

运行这样的命令,它应该工作: ARCHFLAGS=-Wno-error=unused-command-line-argument-hard-error-in-future easy_install pyodbc