python - 试图在 Ubuntu 上安装 grequests?

标签 python ubuntu installation pip grequests

当我尝试使用 pip 在 Ubuntu 上安装 grequests 时:

sudo pip install grequests

我收到此错误,但我的 gcc 似乎没问题:

In file included from gevent/core.c:253:0:

gevent/libevent.h:9:19: fatal error: event.h: No such file or directory

compilation terminated.

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

最佳答案

您需要安装 libevent,在 Ubuntu 上可以通过以下方式完成:

apt-get install libevent-dev 

或者,自动安装 gevent 及其所有依赖项:

apt-get install python-gevent

关于python - 试图在 Ubuntu 上安装 grequests?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19016265/

相关文章:

php - 在Windows中安装或使用php Composer(失败)

installation - 如何创建具有有效签名的预配置安装程序(MSI 或 EXE)?

python - 如何在 Django 中动态调度任务?

laravel - 如何从我的本地计算机访问远程 Elasticsearch 服务器(在 Google Compute Engine 上)

ruby - 如何在 Mac Leopard 上安装 Ruby?

使用 MXE 和 NetworkAuth 的 Qt5 交叉编译

python - Ubuntu 中的 pip 版本不同

python - 按值对 numpy 矩阵进行有效着色?

python - 允许谷歌应用程序的权限后无法连接到本地主机

python - odoo10如何继承其他功能并更新线路?