pip安装uwsgi报错

时间:2024-03-19 11:54:17

pip安装uwsgi是报以下错误:

[[email protected] ~]# pip install uwsgi

pip安装uwsgi报错

Command “/usr/bin/python -u -c “import setuptools, tokenize;file=’/tmp/pip-install-uqbRn0/uwsgi/setup.py’;f=getattr(tokenize, ‘open’, open)(file);code=f.read().replace(’\r\n’, ‘\n’);f.close();exec(compile(code, file, ‘exec’))” install --record /tmp/pip-record-C6Qm8w/install-record.txt --single-version-externally-managed --compile” failed with error code 1 in /tmp/pip-install-uqbRn0/uwsgi/

解决方法

1、首先将pip更新到最新版本

[[email protected] ~]# python -m pip install --upgrade pip

2、安装依赖包(主要依赖问题)

[[email protected] ~]# yum -y install python-devel libevent-devel libjpeg-devel zlib-devel

3、重新安装uwsgi

[[email protected] ~]# pip install uwsgi

pip安装uwsgi报错

备注:
如果安装pillow模块也遇到类似的问题,需要安装上述依赖。