Home » Random Goodies » Multi Python Installer

Multi Python Installer

Have the need to install a newer version of Python but can’t replace the default system version? This typically happens on systems using the yum package manager. I wrote the following script which provides the option of installing Python 2.6.8, 2.7.3, 3.2.3 along with setuptools (easy_install) from source.

The script is easy to use and installs the selected version(s) of your choice side-by-side in /opt:

[root@splice:~> bash install-mpython

Multi-Python & setuptools installer launched.
Supported installation options:

1 : Python 3.2.3
2 : Python 2.7.3
3 : Python 2.6.8
4 : Python 3.2.3, 2.7.3 and 2.6.8
q : Quit

[?] Enter your choice: 2
[+] Proceeding with Python 2.7.3 installation …
[+] Logging to /root/pyinstall.1359691340 …
[+] Downloading …
[+] Extracting …
[+] Compiling …
[+] Python 2.7.3 compiled successfully.
[+] Compilation successfully completed. ‘python2.7’ and ‘easy_install-2.7’ are now readily available.

Multi-Python & setuptools installer launched.
Supported installation options:

1 : Python 3.2.3
2 : Python 2.7.3
3 : Python 2.6.8
4 : Python 3.2.3, 2.7.3 and 2.6.8
q : Quit

[?] Enter your choice: q
[root@splice:~>

The script can be downloaded here
Alternatively, it can be ran directly as follows: bash <(wget -qO- http://gurutek.biz/scripts/install-mpython)

Enjoy 🙂