linux下装python3以及pip3

1.安装python3以及pip的过程

 wget https://www.python.org/ftp/python/3.6.0/Python-3.6.0.tgz 

 tar zxvf Python-3.6.0.tgz  

 ./configure —prefix=/etc/python/python3.6 

 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   #确保pip的时候不会有出错

make && make install

ln -s /etc/python/python3.6/bin/python3.6 /usr/bin/python3

 ln -s /etc/python/python3.6/bin/pip3.6 /usr/bin/pip3

pip3 install requests

 

posted @ 2017-07-26 20:23  beiguuu  阅读(8252)  评论(0编辑  收藏  举报