python3.8源码安装后,pip出现的问题及其使用
环境为centos8,python为3.8.2
一、先简述源码安装的过程
-
1.下载源码包,解压并接入包中
-
2运行configure文件(可指定安装路径./configure --prefix==/xx/xx/xx)
-
3.然后运行make
-
4.再运行make install
二、出现的问题及解决
1.configure: error: no acceptable C compiler found in $PATH
-
问题原因为PATH变量中没有gcc(C语言编译器)。
-
解决:yum install gcc -y(再运行一中的2,、3、4即可)
2.zipimport.ZipImportError: can’t decompress data; zlib not available
-
zlib不可用,也就是Linux里没有安装
-
解决:yum install zlib zlib-devel -y(再运行一中的2,、3、4即可)
3.WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
-
这个问题的出现与你需要安装的模块有关系,安装的模块依赖需要ssl
-
解决:yum install libffi-devel -y(再运行一中的2,、3、4即可)