簡體   English   中英

在 Centos 上安裝 gevent 錯誤 gcc

[英]Installing gevent on Centos error gcc

我已經安裝了所有要求(我認為)但在運行時仍然出現錯誤

pip install gevent

我也嘗試從 github 安裝,但出現以下相同錯誤:

error: command 'gcc' failed with exit status 1

----------------------------------------
Cleaning up...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/gev
ent/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n
', '\n'), __file__, 'exec'))" install --record /tmp/pip-vKU7TO-record/install-record.txt
--single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_
root/gevent
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    load_entry_point('pip==1.5.4', 'console_scripts', 'pip')()
  File "/usr/lib/python2.6/site-packages/pip-1.5.4-py2.6.egg/pip/__init__.py", line 185,
in main
    return command.main(cmd_args)
  File "/usr/lib/python2.6/site-packages/pip-1.5.4-py2.6.egg/pip/basecommand.py", line 16
1, in main
    text = '\n'.join(complete_log)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 30: ordinal not in r
ange(128)

我不確定還有哪些其他信息有用,請告訴我。

如果您仍然需要答案,安裝 libevent-devel 和 python-devel 可以解決這個問題。

yum install libevent-devel
yum install python-devel

使用 yum 為我解決了這個錯誤。

yum install python-gevent

由於某種原因,easy_install 和 pip 在 gevent 上不起作用。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM