3

I'm developer and I need to make my enviroment work with Python 2.7.6 (not 2.7.3) on the Ubuntu 12.04. Please, provide me some notes how to do that?

1
  • Thanx, ! I upgraded form python 2.7.5+ to 2.7.6 on Ubuntu 13.10.I didn't have the need to use the command "sudo update-alternatives --config python", but I had to use "sudo make install" in order to get the permissions to install the update. – user271482 Jul 16 '14 at 8:01
4

Ubuntu 12.04 ships with python 2.7.3. You should be able to download https://www.python.org/ftp/python/2.7.6/Python-2.7.6.tgz and follow the README file. The steps should be simple enough.

./configure
make
make install

Note that you don't have to remove python-2.7.3 from your system to install an other version. You can switch between different versions using

sudo update-alternatives --config python

Also, did you check this out?

https://stackoverflow.com/questions/20445565/ubuntu-12-04-lts-update-python-2-7-3-to-2-7-6-without-breaking-dependencies

1
  • 1
    Switching between 2.73 and 2.7.6 does not work for me ("error: no alternatives for python."). The new version seems to have overwritten the old one. – luator Apr 21 '15 at 10:41
2

On Ubuntu 12.04 or >12.04 this will work perfectly. Run these simple commands in your terminal:

wget  https://www.python.org/ftp/python/2.7.6/Python-2.7.6.tgz  
./configure
make
make install
2
  • 1
    This answer only shows (in addition to the accepted answer) how to download the file via wget from command line. It also misses tar xf(v)z command to unpack archive and a cd into the folder before doing ./configure and so on. – colidyre Jan 14 '20 at 14:00
  • yes that is what only missing in the new_sys_admin answer. This is a complete answer for everyone. – sourav Mar 7 '20 at 0:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.