[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] pygame2exe



On 2010.10.23 11:20 PM, Matt Riche wrote:
I just struggled with this one myself, literally barely 48 hours ago,
and I finally got a solution.

Next I got some error about a failure to initialize "mixer_music".  I
read a lot of discussion on how to fix this, but most people's ideas
didn't work for me.  Someone finally said to roll back to Python 2.5,
and the version of Pygame for it.  That fixed that problem.  Not sure
if there's a better way, or really why that was a fix, but it worked.
Maybe research more before you try that if you don't wanna roll back?
Or more likely, your program doesn't use audio and there won't be
calls to this.

I've had trouble with similar problems like the DLLs, and have settled some of them by (1) never using the default font in a compiled program and (2) sticking to Python 2.5 and matching Pygame. I've tried relying on a simple setup.py rather than some of the fancier workarounds some people have been able to use. The latest version I've been able to dig up from my code looks like this (and reminds me how long it's been):
<code>
# setup.py
from distutils.core import setup
import py2exe
setup(author="Kris Schnee",
      author_email="kschnee@xxxxxxxxxx",
      version="2009.9.26",
      license="GPLv3 or MIT",
      windows=[{"script":"morningside_server.py",
                "icon_resources":[(0,"beach.ico")],
                }])
</code>

That might be a useful template.

c:\users\christ~1\appdata\local\temp\tmplkizod.py

Wow, I didn't know _He_ used Python! =)