源码安装LAMP步骤简述
1.下载python软件包
shell> wget https://www.python.org/ftp/python/3.6.0/Python-3.6.0.tar.xz
2.安装源码编译环境
shell> yum install -y gcc gcc-c++ openssl openssl-devel zlib zlib-devel readline readline-devel
3.解压源码包
shell> tar Jxvf Python-3.6.0.tar.xz -C /usr/local/src/
4.源码编译
shell> cd /usr/local/src/Python-3.6.0
shell> ../configure --prefix=/usr/local/python36 --with-ssl
shell> make && make install
5.创建软链接
shell> ln -s /usr/local/python36/bin/python3.6 /usr/local/bin
shell> ln -s /usr/local/python36/bin/pip3.6 /usr/local/bin
6.测试
shell> python3.6
Python 3.6.0 (default, Dec 27 2021, 04:01:28)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-44)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>