升级python

 

ubuntu:apt-get install gcc zlib* openssl openssl-dev

debian :apt -y install gcc make zlib1g-dev libffi-dev libssl-dev libffi-dev libssl-dev
Centos :yum -y install gcc zlib* openssl openssl-devel
tar -zxvf Python-3.5.2.tgz

./configure  --prefix=/usr/local/python3.5

make all 

make install && make clean && make distclean

mv  /usr/bin/python /usr/bin/python2.7.5
ln -s /usr/local/python3.5/bin/python3 /usr/bin/python
ln -s /usr/local/python3.5/bin/pip3 /usr/bin/pip

 

posted @ 2017-12-12 11:10  _Goku  阅读(124)  评论(0编辑  收藏  举报