[Q] Rolling your own binary distribution/installation of Python 2.0

Gordon McMillan gmcm at hypernet.com
Fri Apr 13 21:48:20 EDT 2001


[posted and mailed]

jcopella at cfl.rr.com (John Copella) wrote in
<hgGB6.3133$fs3.916593 at typhoon.tampabay.rr.com>: 

>Hmmm.  I looked into the "Installer" utility you referred me to (and the
>FAQ another gentleman mentioned) and these are close, but don't quite
>address the problem.  I probably didn't explain this very well, but I
>don't have a top-level script to "freeze" -- which is the precondition
>these tools seem to require.  

Well, no. It's just that that's what most people want to do, so that's what 
I made easy. And in fact, that's the way I'd do it on Windows or Linux: 
package the std lib into a .pyz, then "freeze" a script that examined the 
command line and executed any script specified on it, or ran code.py if 
none was specified.

A .pyz can be built and used anywhere zlib is available (and it wouldn't be 
hard to chop out the zlib where it isn't). I know someone using them on 
AIX, just to cut down startup times. Since you know your exact installation 
configuration, you can take a hatchet to getpath.c, too. You could go 
further, but by doing those things you've got it down to a single-directory 
install, and you're not locked out of using c extension modules or 
packages.

- Gordon



More information about the Python-list mailing list