安装Python时出现pip错误:“忽略surepip错误:pip 8.1.1需要SSL/TLS" [英] pip error while installing Python: "Ignoring ensurepip failure: pip 8.1.1 requires SSL/TLS"
问题描述
我下载了Python 3.5源代码并运行以下代码:
I downloaded the Python 3.5 source code and ran the following:
$ tar -xf Python-3.5.2.tar.xz
$ ./configure --with-ensurepip=upgrade
$ make
$ sudo make altinstall
进展顺利,直到make
. sudo make altinstall
运行时,它打印:
It proceeded well until make
. When sudo make altinstall
ran, it printed:
Ignoring ensurepip failure: pip 8.1.1 requires SSL/TLS
出了什么问题?
推荐答案
您极有可能不使用SSL/TLS支持来编译Python-这很可能是因为您的系统上未安装SSL开发依赖项.
You are most likely not compiling Python with SSL/TLS support - this is likely because you don't have the SSL development dependencies installed on your system.
安装以下依赖项,然后重新配置并重新编译Python 3.5.
Install the following dependency, and then re-configure and re-compile Python 3.5.
Ubuntu
apt-get install libssl-dev
此外,建议安装以下内容.
In addition it is recommended to install the following.
apt-get install make build-essential libssl-dev zlib1g-dev libbz2-dev libsqlite3-dev
CentOS
yum install openssl-devel
此外,建议安装以下内容.
In addition it is recommended to install the following.
yum install zlib-devel bzip2-devel sqlite sqlite-devel openssl-devel
这篇关于安装Python时出现pip错误:“忽略surepip错误:pip 8.1.1需要SSL/TLS"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!