by Francis_hao APR 11,2017
Using the source installation method
First, download the latest version of Python to the official website https://www.python.org/downloads/source/. Current is 3.6.1
After decompression into the source folder, there is a Readme.rst file. Description and how this source package is used.
Normally, you can install by using the following command, [] indicating that the item is optional
./configure
Make
[Make Test]
sudo make install
You can also transfer parameters to the configuration script. View the parameters that can be passed by running the./configure–help. Here we take care of the installation directory section
Python is installed by default in the/usr/local/bin directory, and the current 2.x version of Python is installed in the/usr/bin/directory. So there is no conflict. Of course you can also specify the installation location.
After installation, you can use Python3, which already supports the functions of tab completion and BACKSPACE. The original Python does not change, and Yum has no effect.
This article was authored by Liu Yinghao and licensed under the Creative Commons Attribution-NonCommercial use-Share 3.0 Chinese mainland license agreement in the same way. Welcome reprint, please specify the source:
Reprinted from: http://www.cnblogs.com/yinghao1991/
CentOS 7, upgrade Python to 3.x