问题

我运行Linux(2.6.18-164.15.1.el5.centos.plus)并尝试安装pyodbc.我做pip安装pyodbc和得到一个非常长的错误列表,其结束在

error: command 'gcc' failed with exit status 1

我在 /root/pip/pip.log 中查看了以下内容:

InstallationError: Command /usr/local/bin/python -c "import setuptools; file='/home/build/pyodbc/setup.py'; execfile('/home/build/pyodbc/setup.py')" install --single-version-externally-managed --record /tmp/pip-7MS9Vu-record/install-record.txt failed with error code 1

有人有类似的问题安装pyodbc吗?

谢谢, Igor



解决方法

我在 http://code.google.com上遵循正确的指示,解决了我的问题/ p / pyodbc / wiki / Building 其状态:

On Linux, pyodbc is typically built using the unixODBC headers, so you will need unixODBC and its headers installed. On a RedHat/CentOS/Fedora box, this means you would need to install unixODBC-devel:

yum install unixODBC-devel




相关问题推荐