freeze.py and GTK apps

Kristian Hermansen kristian.hermansen at gmail.com
Tue Mar 28 12:50:53 EST 2006


On 3/28/06, Adam DePrince <adam.deprince at gmail.com> wrote:
> When your Python installation uses shared library modules such as
> _tkinter.pyd, these will not be incorporated in the frozen program.
>  Again, the frozen program will work when you test it, but it won't
>  work when you ship it to a site without a Python installation.

No, it didn't even run!!!  So, it won't run frozen on ANY system.  The
_gtk import choked the whole program and it died with exit status ==
1.  So, even though I did have the GTK libraries locally, the program
exited improperly.  The unfrozen script ran fine, so isn't this a
different problem entirely?

> Freeze prints a warning when this is the case at the end of the
> freezing process:
>
>         Warning: unknown modules remain: ...
>
> When this occurs, the best thing to do is usually to rebuild Python
> using static linking only. Or use the approach described in the previous
> section to declare a library path using sys.path, and place the modules
> such as _tkinter.pyd there.
>
> Same applies here ...

Well, what we want is a totally static frozen build, but if not
possible (GTK is huge right?), GTK is assumed to be on the target
machine.  However, the frozen binary still doesn't run properly.  Any
suggestions?  Try freezing the example code yourself and running it,
perhaps I am doing something amazingly wrong here...
--
Kristian Hermansen



More information about the Python-list mailing list