代码设计工具ReviewBoard安装Python模块出现error: Setup script exited with error: command 'gcc' failed with exit status 1,但是明明已经安装了gcc组件还是无法运行,后来发现是failed不是not found,这说明错误和gcc没多大关系应该是缺少某些功能模块,先后安装了一些列插件python-devel,libffi-devel等还是不行,最后发现要安装openssl-devel才行。
执行easy_install ReviewBoard 命令,具体错误信息如下:
[root@localhost Django-1.5.5]# easy_install ReviewBoard
Searching for ReviewBoard
Best match: ReviewBoard 1.6
...
Moving pyasn1-0.2.3-py2.6.egg to /usr/lib/python2.6/site-packages
Adding pyasn1 0.2.3 to easy-install.pth file
...
removing: _configtest.c _configtest.o
c/_cffi_backend.c:15:17: error: ffi.h: No such file or directory
In file included from c/_cffi_backend.c:63:
c/malloc_closure.h:81: error: expected specifier-qualifier-list before ?.fi_closure?
...
In file included from c/cffi1_module.c:3,
from c/_cffi_backend.c:6740:
c/realize_c_type.c: In function ?.ealize_c_type_or_func?.
c/realize_c_type.c:577: error: ?.FI_DEFAULT_ABI?.undeclared (first use in this function)
c/_cffi_backend.c: In function ?.nit_cffi_backend?.
c/_cffi_backend.c:6832: error: ?.FI_DEFAULT_ABI?.undeclared (first use in this function)
error: Setup script exited with error: command 'gcc' failed with exit status 1
解决方案:
执行yum install gcc libffi-devel python-devel openssl-devel命令,具体命令如下:
[root@localhost Django-1.5.5]# yum install gcc libffi-devel python-devel openssl-devel
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
* base: mirrors.tuna.tsinghua.edu.cn
* extras: mirrors.tuna.tsinghua.edu.cn
* updates: mirrors.tuna.tsinghua.edu.cn
Setting up Install Process
Package gcc-4.4.7-17.el6.x86_64 already installed and latest version
Package python-devel-2.6.6-66.el6_8.x86_64 already installed and latest version
Package openssl-devel-1.0.1e-48.el6_8.4.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package libffi-devel.x86_64 0:3.0.5-3.2.el6 will be installed
--> Finished Dependency Resolution
安装ReviewBoard时错误解决方案推荐: