Centos7下安装python3.7.9

  • Post author:
  • Post category:python


下载地址:

https://www.python.org/ftp/python/3.7.9/Python-3.7.9.tgz


#安装环境centOS 7


#安装依赖包:

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

在centos7必须获取root的权限,在操作下面步骤:

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

mkdir -p /usr/local/python379

tar zxvf Python-3.7.9.tgz

cd Python-3.7.9

./configure –prefix=/usr/local/python356

make

make install

ln -s /usr/local/python379/bin/python3 /usr/local/bin/python3

ln -s /usr/local/python379/bin/pip3 /usr/local/bin/pip3

pip3 install –upgrade pip  #更新pip

pip3 install ipython  #安装ipython



版权声明:本文为qq_33435149原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。