“Centos7 python3 and pip3 How to install python3.x on centos7.x”的版本间的差异

来自linux中国网wiki
跳到导航 跳到搜索
第24行: 第24行:
 
</pre>
 
</pre>
  
 +
 +
 +
=python源码国内下载=
 +
 +
https://mirrors.huaweicloud.com/python
  
 
=troubleshooting=
 
=troubleshooting=
第30行: 第35行:
  
 
安装上所有的lib 用上面的安装方式就行了
 
安装上所有的lib 用上面的安装方式就行了
 
  
 
=see also=
 
=see also=

2021年6月17日 (四) 06:07的版本


yum -y groupinstall "Development tools" 

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

 wget -c https://www.python.org/ftp/python/3.5.1/Python-3.5.1.tgz
   21  tar xvf Python-3.5.1.tgz 
   23  cd Python-3.5.1/

   25  ./config
   26  ./configure 
   27  ./configure --prefix=/usr/local/python3
   28  make -j4  && make install

创建Python3,pip3的软链接
ln -s /usr/local/python3/bin/python3.5 /usr/bin/python3
   78  ln -s /usr/local/python3/bin/pip3  /usr/bin/pip3






python源码国内下载

https://mirrors.huaweicloud.com/python

troubleshooting

zipimport.ZipImportError: can't decompress data; zlib not available

安装上所有的lib 用上面的安装方式就行了

see also

Centos7 Python3 pip3下安装scrapy