Install Python 3.8 in CentOS 7
Update Yum repository and install prerequisite packages.
# sudo yum update -y
# sudo yum -y groupinstall “Development Tools”
# sudo yum install gcc openssl-devel bzip2-devel libffi-devel wget
Download Python package.
# wget https://www.python.org/ftp/python/3.8.3/Python-3.8.3.tgz
Extract Downloaded Package.
# tar xvf Python-3.8.3.tgz
Change Directory.
# cd Python-3.8.3
Install Python 3.8
Run installation by running configuration script. (Use 2 hyphens before – –enable-optimizations )
# sudo ./configure –enable-optimizations
Run make altinstall. (Not replaced base system python package (/usr/bin/python)
# sudo make altinstall
Check Python Version.
# python3.8 -V