February 13 2012

Generate python (using pygtk) executables using py2exe (win32)

I’m getting old…real old…now I need to write everything down in case they somehow slip my mind…
I’ve been trying to generate executables for my little program written in Python, under both x64 and Linux(Ubuntu 11.04), and with various programs…but I haven’t been really successful, despite the fact that I might not have put in enough effort as well… As a matter of fact, none of my executable really works on others’ machine. (works perfect on my own PC though)
Anyway, now there is something which seems to be working…the environment is x86 this time…with the help of py2exe
So again, I’m getting old, and I’m writing it down…
For record, the following is basically a combination of several recipes found on the web, I don’t really have any personal contribution to this…
So, py2exe should normally work with simple programs, a ‘hello world’ for example…but things just get complicated once PyGtk and Matplotlib are involved…
Let’s have a look at my setup.py first…
Continue reading