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

Re: [pygame] py2exe / OpenGL Build Trouble



Dave LeCompte (really) wrote:
"Kris Schnee" <kschnee@xxxxxxxxxx> wrote
I just built an EXE using Pygame and PyOpenGL, and the EXE crashes with
this message:

I think it depends on what version of PyOpenGL and Py2EXE you have
installed - the documentation here seems to think it's no longer a
problem:

What I ended up doing was rewriting the __version__ assignment in
__init__.py, like so:

try:
    filename = os.path.join(os.path.dirname(__file__), 'version')
    __version__ = string.strip(open(filename).read())
except Exception,err:
    __version__ = '2.0.2.01'


Clearly a hack, but it's worked so far. You may want to verify what
version of PyOpenGL you have installed before you apply it to your own
machine...


Quick reply: I made that change to the __init__.py file, and the EXE now works -- so, thanks. Unfortunately I don't seem able to install the new version of PyOpenGL, though! The Sourceforge page offers a source ZIP with no Windows installer, and when I use "python setup.py" on the source, I get an error about -- I don't have it offhand, but some sort of missing module like "setuptools."