[Distutils] easy_install and Unix python with sys.prefix different from sys.exec_prefix

Berthold Höllmann berthold at despammed.com
Thu Nov 16 18:25:33 CET 2006

"Phillip J. Eby" <pje at telecommunity.com> writes:

> At 04:01 PM 11/16/2006 +0100, Berthold Höllmann wrote:
>>I'll certainly give it a try, but why so much hassle for the person
>>installing, when the required information is easily avaliable for the
>>easy_install tool? Hey I read "easy_install" ;-)
> Precisely!  Your current directory layout and sharing are intended to work 
> around the fact that in the past, installation of Python packages has *not* 
> been easy for you.  If you were starting today, you wouldn't *bother* to do 
> such a complex setup as you're doing, because:
>    It would actually be EASIER to just run easy_install ONCE for
>    each machine or Python installation you needed a package
>    installed for!

Compared to a "wget <path to package>", (which is still required for
some of the packages I need), untaring the result and "python setup.py
install"? Yes it is for extension. But for modules I doubt. An often
what I think is a pure python module really contains an extension
module and vice versa, which than requires some cleanup.

No, it won't really. Our main software is always changing. It consits
of a set of quite stable extensions and a big, ever changing pure
python module. Installing the whole stuff on three platforms after
every change is quite annoying, it is much easier to do the
installation of the module on only one platform and benefit from the
changes imediately on the others. This is why we choose the actual

> (It would also be simpler, as there would be no NFS, no split 
> prefix/exec-prefix, etc., etc.  At most, you could have an NFS cache 
> directory to save on repeated downloads, as I suggested in a previous post.)

I still had to do three installs instead of one for every required
module. An not every module or extension allows easy installation now
(I need pytables which requires numarray, but easy_install on the
latest numarray tar does not install the require header files).

> So the problem isn't that easy_install is hard, the problem is that you're 
> attempting to make it do something that's really not necessary, because 
> you're accustomed to doing it that way.  Nonetheless, I have given you 
> instructions to make it work; you just don't like them.  :)
>>This still does not solve the problem with the "#!" or shebang lines
>>in scripts.
> There is no problem, as I understand it.  Install scripts to the 
> exec_prefix/bin directories, and they will run the appropriate Python.

Again three installs for one module instead of one.

>>Especially when installing modules, I think using the full
>>path to the python executable is wrong.
> Ah, there's the problem!  Just stop thinking that, and all will be fine.  ;)
>>I'm still pleading for a way to customize the string after the "#!" part.
> If you really want to spend the effort to do that, I suggest you look at 
> zc.buildout, which extensively wraps setuptools and contains its own #! 
> generation.  However it will likely be a lot of work for you to do, to 
> satisfy a concern that is purely a matter of taste rather than functional 
> necessity.  (Assuming, again, that I actually understand your requirements 
> correctly.)

Maybe I could clear our requirements.

                            __   Address:
                         G /  \ L Germanischer Lloyd
phone: +49-40-36149-7374 -+----+- Vorsetzen 35       P.O.Box 111606
fax  : +49-40-36149-7320   \__/   D-20459 Hamburg    D-20416 Hamburg

More information about the Distutils-SIG mailing list