错误名称:
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
实际上是python编译SSL的时候出错,下面来看下解决方法
0.环境说明:
①python3.7.2
②centos 7.4
1.安装依赖包:
1
|
yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel
|
2.打开ssl代码块儿 Python-3.7.2/Modules/Setup.dist 并让下面的配置可用
cd ***/Python-3.7.2 #***是你存放python的目录的位置 vi Modules/Setup.dist
3.接下来重新编译Python就不会报SSL错误了:
make clean ./configure --with-openssl=/usr/local/openssl --enable-optimizations make make install
近期评论