Python installation in Linux
Compile and install it in the Python-2.7.3 root directory./configure supplement: After the configure command is executed, a Makefile file is generated. This Makefile is mainly used by the next make command. Open Makefile and you will find that the build sequence is set in it. Linux needs to build program components according to the sequence specified by Makefile. Make actually compiles your source code and generates an execution file. Run the make install command to make install to copy the generated execution file to the necessary directory in linux, for example, to the/usr/local/bin directory, in this way, all users can run this program. Python installation is complete. It should be said that, in fact, other linux software installation is similar, basically all need to go through the configure> make install process. After Hello World is installed, run the python command, you will find that the default python command still points to the old version 2.4.3 [admin @ bej301441 bin] $ which python/usr/local/bin/python to execute the which python command, you will find that the default python is in the/usr/local/bin/python directory. In fact, the newly installed python is also in this directory. Enter python2.7 in the command line to execute the new python version. Create a "hello. py" file on Linux and write only one line of code print "Hello PTIAN" in it, and then run python2.7 hello. py.