CentOS6.9安裝python3.7
阿新 • • 發佈:2018-12-22
楔子
CentOS6.9升級python3.7
安裝
1 依賴環境
yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel
2 注意
centos下安裝python3.7.0以上版本時報錯ModuleNotFoundError: No module named '_ctypes’的解決辦法
yum install libffi-devel -y
3 下載安裝
wget https://www.python.org/ftp/python/3.7.1/Python-3.7.1.tgz
## 解壓進入目錄
./configure
make
make install
如上圖所示,pip自動安裝
pip安裝mycli
提示
require TLS/SSL
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
You are using pip version 10.0.1, however version 18.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
沒事動yum 和pip