Install Python in CentOS
Install gcc before installing python
Yum install gcc
Find your desired pythonversion at https://www.python.org/ftp/python /.
Like https://www.python.org/ftp/python/3.4.1/Python-3.4.1.tgz
Download python
Wget https://www.python.org/ftp/python/3.4.1/Python-3.4.1.tgz
Decompress, compile, and install
# Tar zxvf Python-3.4.1.tgz
# Cd Python-3.4.1.tgz
#./Configure
# Make
# Make install
At this time, the new version of python does not overwrite the original version.
Vi/user/bin/yum
Change the first line of python to python2.7.
# Mv/usr/bin/python/usr/bin/python2.7
Recreate a hyperlink
# Ln-s "python download and compilation directory" (Space)/usr/bin/python
Open python again to display the new version
# Python
Python 3.4.1 (default, Aug 25 2014, 10:04:52)
Type "help", "copyright", "credits" or "license" for more information.
>>>
Installed successfully!
You may also like the following article about Python:
Installation of Python in Linux and precautions
Install and use the Python rq module in Ubuntu 14.04
Directly run Python code without the need for the operating system
Install Python3.4 on CentOS source code
Python core programming version 2. (Wesley J. Chun). [Chinese version of hd pdf]
Python development technology details. (Zhou Wei, Zong Jie). [hd PDF scan version + book guide video + code]
Obtain Linux information using a Python script
Build a desktop algorithm transaction research environment using Python in Ubuntu
A Brief History of Python Development
Python details: click here
Python: click here
This article permanently updates the link address: