在Centos7.4安装python3.7

  • Python3.7

    Refered from How to Install Python 3.7 on CentOS/RHEL 7/6 & Fedora 32/3`.

    yum install gcc openssl-devel bzip2-devel libffi-devel
    cd /usr/src
    wget https://www.python.org/ftp/python/3.7.7/Python-3.7.7.tgz
    tar xzf Python-3.7.7.tgz
    cd Python-3.7.7
    ./configure --enable-optimizations
    make altinstall
    rm /usr/src/Python-3.7.7.tgz
    python3.7 -V
    

    如果出现make not found, just yum install make

你可能感兴趣的:(Linux,小白学Python)