Python 2.7 installation problem

Ronald Guida oddron at gmail.com
Sun Sep 26 08:19:59 CEST 2010


Hi,

I am trying to perform a user-install of python 2.7 on Ubuntu 10.04, and my
installation is failing.

This sequence of commands reproduces the failure on my system:

$ tar -zxvf Python-2.7.tgz
$ cd Python-2.7/
$ ./configure --prefix=$HOME
$ make
$ ./python Lib/test/test_collections.py
doctest (collections) ... 54 tests with zero failures
$ make altinstall
$ cd
$ which python2.7
/home/oddron/bin/python2.7
$ python2.7
Python 2.7 (r27:82500, Sep 26 2010, 01:49:59)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import collections
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/oddron/lib/python2.7/collections.py", line 8, in <module>
    from _collections import deque, defaultdict
ImportError: No module named _collections
>>> import sys
>>> sys.path
['', '/home/oddron/lib/python27.zip', '/home/oddron/lib/python2.7',
'/home/oddron/lib/python2.7/plat-linux2',
'/home/oddron/lib/python2.7/lib-tk', '/home/oddron/lib/python2.7/lib-old',
'/home/oddron/lib/python2.7/lib-dynload',
'/home/oddron/.local/lib/python2.7/site-packages',
'/home/oddron/lib/python2.7/site-packages']
>>>


Things I have already checked:
* My path includes ~/bin
* None of PYTHONHOME and friends are set.
* I have also tried "make install" instead of "make altinstall", and I get
the same failure.

Can anyone give me a hint regarding what has gone wrong?

Thank you
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100926/aa12c357/attachment.html>


More information about the Python-list mailing list