I need python 3.2 for development purposes, but new ubuntu 13.04 comes with python 3.3.

is there any best practice for installing older python version into ubuntu?


  • 2
    Any specific reason you'd need 3.2? Is there a feature in it which is not in 3.3? – dobey May 15 '13 at 21:40
  • 1
    No, but there is 3.2 on the production server and I would like to work on the same version. – JoshuaBoshi May 16 '13 at 10:37

Use the Deadsnakes PPA, which includes a range of Python versions packaged for a range of Ubuntu versions, including 3.2 for raring.

sudo apt-add-repository ppa:fkrull/deadsnakes
sudo apt-get update
sudo apt-get install python3.2
  • 1
    This is exactly the answer I was waiting for.. thank you very much! – JoshuaBoshi May 16 '13 at 21:34

Download and compile Python (with the terminal):

wget http://python.org/ftp/python/3.3.0/Python-3.3.0.tar.bz2
tar jxf ./Python-3.3.0.tar.bz2
cd ./Python-3.3.0
./configure --prefix=/opt/python3.3
make && sudo make install

Source: AskUbuntu

  • If I overlook that I want to install 3.2 (not 3.3), I guess this answer should be "compile it". I am ok, with this answer, but I would like to know if there is any better option - prepared packages maybe. – JoshuaBoshi May 16 '13 at 10:40

Other options I've come across are pyenv and pythonz - they both will build custom versions of python (including PyPy and Jython) for you and allow you to change the python you use in the terminal.

I haven't tried either myself so can't recommend one.

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.