Shipping embedded Python project

Thomas Heller theller at python.net
Mon May 10 11:22:23 EDT 2004


Miki Tebeka <miki.tebeka at zoran.com> writes:

> Hello,
>
> I've extended a C++ project with Python.
> I'd like to ship the new project with all the required Python modules
> but *without* installing Python on client machines.
>
> I know that py2exe/Installer/cx_freeze ... know how to find which
> modules are needed and pack them.
>
> Is there a "standard" way to do this? I didn't find anything in the docs.

py2exe and cx_freeze (not 100% sure about the latter) use modulefinder
to find the modules needed.  Installer has it's own mf5.py.

Or you use py2exe to build a zip-compatible archive, and insert it into
sys.path in your program.  Do not specify any of the console and windows
options, and pass your 'main-module' with the --includes command line
option.  py2exe will happily create a dist directory for you, without an
exe-file.

Thomas





More information about the Python-list mailing list