centos升级python2.6到python2.7及相关库安装

下面列一下centos系统升级python到2.7以及安装相关库的步骤:

 

1 wget http://python.org/ftp/python/2.7.5/Python-2.7.5.tgz

2 tar xvf Python-2.7.5.tgz

3 cd Python-2.7.5

4 ./configure 

5 make all

6 sudo make install

7 make clean

8 make distclean

9 sudo mv /usr/bin/python /usr/bin/python2.6

10 sudo ln -s /usr/local/bin/python2.7 /usr/bin/python

到此python已经升级到2.7.5

 

下面再列一下一些相关库的安装:

1 wget https://bootstrap.pypa.io/get-pip.py

2 sudo python get-pip.py 

3 sudo pip install tornado

4 export PYCURL_SSL_LIBRARY=nss

5 sudo pip install --compile --no-cache-dir pycurl

 

 

 

 

你可能感兴趣的:(centos,python)