[Distutils] Fwd: installing lxml ? - todays user experience from python-list at python.org

David Cournapeau cournape at gmail.com
Wed Nov 11 15:58:16 CET 2009


On Wed, Nov 11, 2009 at 11:10 PM, Maurits van Rees
<m.van.rees at zestsoftware.nl> wrote:
> David Lyon, on 2009-11-11:
>> $ sudo STATIC_DEPS=true /Library/Frameworks/Python.framework/Versions/
>> 2.6/bin/easy_install lxml
>> Password:
>> sudo: STATIC_DEPS=true: command not found
>
> On linux 'true' is a command:
> $ whatis true
> true (1)             - do nothing, successfully

 I would advise against using sudo easy_install. This will cause
trouble by mixing the system python and the softwares it expects vs.
custom ones. If it were me, I would even raises an exception in
easy_install if run under root without any prefix option. That's an
ever-ending source of trouble.

Most of the OP problems have nothing to do with easy_install or even
python, but with sudo. sudo does not propagate env variables (more
exactly, it has strict rules about which variables to reuse). Do not
use sudo, and your problem will disappear. On python 2.6, a good way
to avoid sudo is to use --local to  install things in $HOME/.local (I
don't know how to do that from easy_install --local is an install
option to distutils). Otherwise, install things in a directory which
is in your PYTHONPATH. I for example use $HOME/local on mac os x, and
install everything there for python < 2.6.

David


More information about the Distutils-SIG mailing list