Tinkering with py2exe
Ishwor
ishwor.gurung at gmail.com
Sat Dec 25 19:52:58 EST 2004
On 25 Dec 2004 16:26:01 -0800, John Machin <sjmachin at lexicon.net> wrote:
>
> Ishwor wrote:
> > Having coded 1.72kb python test file, i decided to convert it to .exe
> > file using py2exe.
> > Having succeded doing it, i found the need to distribute the whole
> > directory including these files ?!!!???
> > 26/12/2004 09:16 AM 203,096 library.zip
> > 26/11/2004 09:16 AM 1,867,776 python24.dll
> > 26/12/2004 09:16 AM 11,264 simpletable.exe
> > 26/11/2004 09:16 AM 4,608 w9xpopen.exe
> > 4 File(s) 2,086,744 bytes
> >
> > i assume w9xpopen.exe does the work around to run the code in
> windows.
>
> No, it is required to make the popen* functions work correctly on "w9x"
> platforms (Windows 95, 98, & ME).
okay.. double clicking it returns the same remarks.
>
> > python24.dll (which is massive 1.78mb!!)- has the Python VM i guess.
> > what does the library.zip do??
>
> (1) Aren't you curious enough to try peeking into it with WinZip or
> similar?
>
i didn't find anything to peek. all the files were compiled .pyc's
inside the zip file.. :-(
> (2) Perhaps you should have read all the way through the py2exe home
> page:
yup. i should have read everything from top to bottom but i was
extremely eager to see py2exe in action and just copy pasted the
setup.py and alikes.
>
> """
> How does it work?
> py2exe uses python's modulefinder to examine your script and find all
> python and extension modules needed to run it. Pure python modules are
> compiled into .pyc or .pyo files in a temporary directory. Compiled
> extension modules (.pyd) are also found and parsed for binary
> dependencies.
>
> A zip-compatible archive is built, containing all python files from
> this directory. Your main script is inserted as a resource into a
> custom embedded python interpreter supplied with py2exe, and the
> zip-archive is installed as the only item on sys.path.
> """
>
> >
> > Currently to convert such a small script to exe why the nuances of
> 1.98mb??
>
> It's not compiling and linking, as with (say) C. It's packaging,
> providing the minimum (more or less) bundle of resources that you can
> distribute to users who want/need to run your script but
> can't/don't/shouldn't have a full Python distribution. The overhead of
> the pythonXY.dll etc can be spread over multiple scripts.
Yup reading the page. Thanks heaps for that.. Sorry if i was a bit balmy. :-)
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
--
cheers,
Ishwor Gurung
More information about the Python-list
mailing list