Finding all files for embedded distribution

Howard Lightstone howard at
Sun Jan 5 20:24:29 CET 2003

Yet another embedding question.......

I have embedded Python (and Tkinter, Pmw, Blt, Pycdx,...) in an application 
which I want to build a "distribution" for.  Of course, my application 
starts with a C++ main module and not a Python script.  Both Installer and 
Py2exe start from python scripts so .... how would I go about figuring out 
all the python library scripts needed to run?

For debugging, I do have a Python-only startup script which runs just the 
GUI part of things (and not the real-time portions).  I don't mind having 
to set up my own "paths" for things but I am somewhat baffled in finding 
out all the nested imports.  Just in my own scripts (about 45 files), I 
have lots of imports.  

I suppose it would be possible to just copy the whole Python library to the 
distribution CD but that seems like overkill.

Should I be patching something from py2exe or Importer to report imports 
(and where would I start)?

Any help would be greatly appreciated (since I left this to the last 
thing/minute, as usual).


More information about the Python-list mailing list