I'm trying to install setuptools. When I run "sh setuptools-0.6c9-py2.4.egg" I get the following message:
Permission denied:
'/usr/lib/python2.4/site-packages/test-easy-install-26338.write-test'
It is expectable, since I do not have root permissions on the system. Some how I came to the idea of creating a "Virtual" Python.
I download "virtual-python.py" and run it using the site-wide Python. It creates "lib", "bin" and "include" sub-directories in my home-directory. In the end of the output of "virtual-python.py" I see the following message:
You're now ready to download
ez_setup.py, and run
/home/myname/bin/python ez_setup.py
I download this file and run it. But than I get the same error message:
Permission denied:
'/usr/lib/python2.4/site-packages/test-easy-install-925.write-test'
OK. I use "prefix" to force ez_setup.py to write to the local directory:
/home/myname/bin/python ez_setup.py --prefix=~
And then I get:
- You can set up the installation directory to support ".pth" files by
using one of the approaches described
here:
http://peak.telecommunity.com/EasyInstall.html#custom-installation-locations
So, I am redirected to the same page which I read before. So, I do not know what to do now.
I also have another hint:
- You can add the installation directory to the PYTHONPATH
environment variable. (It must then
also be on PYTHONPATH whenever you run
Python and want to use the package(s)
you are installing.)
But if I type:
PYTHONPATH=/home/myname/lib/python2.4/site-packages
I still get the same result as if Python does not see my environment variables.
Can anybody, pleas, help me with that?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…