# yum install zlib-devel # yum install readline-devel
注:readline-devel包用於解決退格鍵與方向鍵出現亂碼的問題python
# wget https://www.python.org/ftp/python/3.6.2/Python-3.6.2.tgz
# tar -xzvf Python-3.6.2.tgz
# cd Python-3.6.2
# ./configure --prefix=/usr/local/python3
注:添加prefix前綴指定安裝的目標路徑測試
# make && make install
# ln -s /usr/local/python3/bin/python3.6 /usr/bin/python3
# python3 --version # python3