[Distutils] Egg support for system packages (including bdist_wininst)
Phillip J. Eby
pje at telecommunity.com
Thu Dec 22 16:42:41 CET 2005
At 12:48 PM 12/22/2005 +0100, M.-A. Lemburg wrote:
>I'd just wish that this would be the default and the .egg ZIP
>file installation approach be made an option.
>
>setuptools would then finally be compatible to the rest of the
>distutils world again and avoid all the added overhead and
>problems of ZIP file imports.
>
>Perhaps you could have two commands, e.g. the default install
>would create the normal package directory (with added .egg-info
>dir) and a new install_eggfile to install the .egg ZIP file
>instead.
The only way this could happen is to add a manifest of installed files, in
order to allow uninstallation and upgrades to be made safe in the absence
of a packaging system. The .egg file/directory technique currently makes
uninstallation as simple as "rm -rf package-version.egg", and multi-version
installs work with no special action.
Note, too, that using .egg files or directories means that installation
*never breaks existing programs* as long as they have specified their
dependencies accurately. Traditional distutils installation is destructive
in the absence of a system packager.
However, if you *have* a system packager, then you should not be using
"setup.py install" anyway, so I'm not sure I see how this is an issue. You
should be simply building system packages. And it's quite straightforward
to make most bdist_* commands work: bdist_wininst and bdist_dumb work with
setuptools "out of the box" because they call the "install" command
internally; only bdist_rpm required some monkeypatching to add
--single-version-externally-managed, because it writes script files that
run "install" later.
Anyway, I guess what I'm saying is, if you want traditional distutils-style
installation, you should use system packages, since they're the only way to
allow uninstallation and avoid corrupted upgrades. Otherwise, you should
use .egg files or directories, in which case easy_install (and in the
future, nest) will be your package manager.
More information about the Distutils-SIG
mailing list