Python环境安装的注意卡点

python 默认是指Python2,Python和Python3 是两个东西,所以下面的不同Python版本解决依赖的安装包也不同

 

系统环境依赖有如下gcc报错:

x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c Ft/Lib/src/number.c -o build/temp.linux-x86_64-2.7/Ft/Lib/src/number.o
Ft/Lib/src/number.c:7:20: fatal error: Python.h: No such file or directory
    #include <Python.h>

安装依赖包

yum install python-devel # Python2版本
yum install python3-devel # Python3 版本


# pip 下载超时的包,使用 wget -c 断点续传或其他服务器拷贝,本地安装tar包即可
wget https://files.pythonhosted.org/packages/78/c4/0c59bf329240981fd3a228ac809a82d00d4b147a82555eb4dddba2d041aa/gevent-20.9.0.tar.gz
pip install gevent-20.9.0.tar.gz


 



posted @ 2020-12-04 14:36  yangxl-dev  阅读(132)  评论(0)    收藏  举报