The latest version of Python 3 at the official website is 3.5.0, and here is my installation process on CentOS 6.6 64bit:
1, download the Python 3 source code
# cd/usr/local/src/
# wget Https://www.python.org/ftp/python/3.5.0/Python-3.5.0.tgz
2, decompression python-3.5.0.tgz
# TAR-XZVF Python-3.5.0.tgz
3. Compile and install Python-3.5.0
# CD Python-3.5.0
./configure Compile Command:
# make
Install Command:
# make Install
A large number of warning were found during the compilation process, but the final installation was successful. The following is the final screenshot of the installation:
5, Configuration environment (CentOS 6.5 from Python2)
Python3.5 is installed by default in the/usr/local/bin directory without creating a linked file, and the system automatically creates Python3 soft links, which point to python3.5, which we can execute directly on the command line Python3
See the screenshot below
While python2.7 and python3.5 can coexist, see the screenshot below
Reference documents
[1].http://www.centoscn.com/image-text/install/2015/0503/5345.html