Home | Rules and Guide | Sign In/Create Account | Write a Post | Reddit | | #ludumdare on irc.afternet.org (Info)

Ludum Dare 29 — April 25th-28th Weekend [9 PM EST] — Theme: ??? (Slaughter Ends Soon!)
  • Ludum Dare 29 Compo (48 Hour+Solo+Scratch+Src) Begins: in 6 days, 18 hours, 7 minutes, 19 seconds
  • Ludum Dare 29 Jam (72 Hour+Teams OK+Relaxed) Begins: in 6 days, 18 hours, 7 minutes, 20 seconds
  • [ MiniLD 50 | Warmup Weekend April 19th-20th | Real World Gatherings | Ludum Deals | Wallpaper ]


    PyOpenGL + Py2Exe Woes

    Posted by
    July 7th, 2008 10:20 am

    Ok, I’ve been trying to make an executable of my game all morning but I can’t make it work. PyOpenGL 3.x has always been a problem because of the setuptools, but in 3.0.0b1 I had a working solution, sort of. Now, however, I can’t get that to work and am just running into this error over and over:

    “RuntimeError: Unable to find an implementation for the ‘win32′ (‘nt’) platform”

    The only things I could find online are similar problems with no responses or solutions.

    Does anybody have any advice?

    Tags:

    4 Responses to “PyOpenGL + Py2Exe Woes”

    1. Can you use pyopengl 2.x?

      http://thorbrian.com/pyopengl/builds.php

      It might take a bit of porting, because pyopengl 3.x broke a few parts of the api.

    2. Pascal Giard says:

      Some trickery à la FretsOnFire 1.3.110…
      First copy the .egg:
      cp -Lr $(PYTHON_LIBS)/site-packages/PyOpenGL-3.0.0a5-py2.5.egg data/
      cp -Lr $(PYTHON_LIBS)/site-packages/setuptools-0.6c8-py2.5.egg data/

      Then add them to sys.path:

      # This trickery is needed to get OpenGL 3.x working with py2exe
      if hasattr(sys, “frozen”) and os.name == “nt”:
      import ctypes
      from ctypes import util
      sys.path.insert(0, “data/PyOpenGL-3.0.0a5-py2.5.egg”)
      sys.path.insert(0, “data/setuptools-0.6c8-py2.5.egg”)

      Please let me know if this solves your issue.

    3. Anonymous says:

      Replace the OpenGL/platforms in dist with the OpenGL/platforms in your sitepackages.

    Leave a Reply

    You must be logged in to post a comment.


    All posts, images, and comments are owned by their creators.

    [cache: storing page]