Fix Python – Combine –user with –prefix error with setup.py install

I was trying to install Python packages a system I recently gained access to. I was trying to take advantage of Python’s relatively new per user site-packages directory, and the new option –user. (The option is currently undocumented, however it exists for Python 2.6+; you can see the help by running python setup.py install –help.)
When I tried ….

Fix Python – how to install python distutils

I just got some space on a VPS server(running on ubuntu 8.04), and I’m trying to install django on it. The server has python 2.5 installed, but I guess its non standard installation. When I run install script for django, I get
amitoj@ninja:~/Django-1.2.1$ python setup.py install
Traceback (most recent call last):
File “setup.py”, line 1, in

Fix Python – DistutilsOptionError: must supply either home or prefix/exec-prefix — not both

I’ve been usually installed python packages through pip.
For Google App Engine, I need to install packages to another target directory.
I’ve tried:

pip install -I flask-restful –target ./lib

but it fails with:

must supply either home or prefix/exec-prefix — not both

How can I get this to work?
….

Fix Python – How can I make setuptools install a package that’s not on PyPI?

I’ve just started working with setuptools and virtualenv. My package requires the latest python-gearman that is only available from GitHub. The python-gearman version that’s on PyPI is an old one. The Github source is setuptools-compatible, i.e. has setup.py, etc. Is there a way to make setuptools download and install the new version instead of lo….

Fix Python – Including non-Python files with setup.py

How do I make setup.py include a file that isn’t part of the code? (Specifically, it’s a license file, but it could be any other thing.)
I want to be able to control the location of the file. In the original source folder, the file is in the root of the package. (i.e. on the same level as the topmost __init__.py.) I want it to stay exactly there w….

Fix Python – Differences between distribute, distutils, setuptools and distutils2?

The Situation
I’m trying to port an open-source library to Python 3. (SymPy, if anyone is wondering.)
So, I need to run 2to3 automatically when building for Python 3. To do that, I need to use distribute. Therefore, I need to port the current system, which (according to the doctest) is distutils.

The Problem
Unfortunately, I’m not sure what’s ….