[Distutils] formencode as .egg in Debian ??

Phillip J. Eby pje at telecommunity.com
Tue Nov 22 23:59:00 CET 2005


At 11:25 PM 11/22/2005 +0100, Martin v. Löwis wrote:
>M.-A. Lemburg wrote:
>>Doesn't the standard "python setup.py install" work with
>>eggified packages anymore (meaning that the package is
>>installed as normal site-packages package) ?
>
>No. First, an eggified package tries to download ez_setup
>first, i.e. it won't do the distutils setup(),

Please try to check these facts a little more closely.  First of all, these 
packages do *not* download ez_setup.  ez_setup is simply a tool to ensure 
that *setuptools* is installed.  Quite reasonably, a package that uses 
setuptools in its setup script, requires that setuptools be present on the 
machine.  ez_setup allows packages to do this without requiring the user to 
manually download and install setuptools.  Instead, the user runs "python 
setup.py install", and the issue of downloading the setuptools egg is 
handled as a convenient byproduct.  If a sufficiently-recent version of 
setuptools is already available, and the package has no other unsatisfied 
dependencies, no downloading occurs.


>but the easy_install
>one. Then, "setup.py install" will not install into, say,
>site-packages/mxTools, but into
>site-packages/mxTools-2.0.3.egg/mxTools, and add, to easy_install.pth,
>the line
>
>/usr/lib/python2.3/site-packages/mxTools-2.0.3.egg
>
>(which in turn adds this directory to sys.path)

Note that if a distutils project uses the extra_path argument, the exact 
same two things will happen, except that each project will get its own .pth 
file, or a collision will occur if two projects use the same .pth name.

You can't reasonably claim that this layout is somehow not a distutils 
layout; packages like Numeric have been using extra_path installs for years.


>If you edit setup.py to use distutils setup instead of
>easy_install setup, it will install as before, but warn
>that setup() is being passed unrecognized parameters.

And depending on the package, a variety of features will then fail to 
operate correctly, either at build time, sdist time, or run time.



More information about the Distutils-SIG mailing list