py2exe and OpenGL problem

Discussion in 'Python' started by bigredindian@gmail.com, Sep 25, 2005.

  1. Guest

    I am using the new py2exe and python 24. When I run my setup.py, the
    dist seems to generate just fine. However run I run the resulting exe,
    I get an error:

    IOError: [Errno 2] No such file or directory
    'c:\\app\\dist\\library.zip\\OpenGL\\version'

    Now I've tried the recommended route with older py2exes, where I
    exclude OpenGL and copy the entire directory over to my dist, but that
    didn't work. I included "version" into the "OpenGL" directory via my
    setup.py script, and it is there right in the library.zip, but I still
    get the same error.

    Anyone have any ideas or suggections?

    Thanks,
    Patrick
     
    , Sep 25, 2005
    #1
    1. Advertising

  2. Line 13:17 of OpenGL.__init__.py, replace with:

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

    HTH,
    Mike

    wrote:

    >I am using the new py2exe and python 24. When I run my setup.py, the
    >dist seems to generate just fine. However run I run the resulting exe,
    >I get an error:
    >
    >IOError: [Errno 2] No such file or directory
    >'c:\\app\\dist\\library.zip\\OpenGL\\version'
    >
    >Now I've tried the recommended route with older py2exes, where I
    >exclude OpenGL and copy the entire directory over to my dist, but that
    >didn't work. I included "version" into the "OpenGL" directory via my
    >setup.py script, and it is there right in the library.zip, but I still
    >get the same error.
    >
    >Anyone have any ideas or suggections?
    >
    >


    --
    ________________________________________________
    Mike C. Fletcher
    Designer, VR Plumber, Coder
    http://www.vrplumber.com
    http://blog.vrplumber.com
     
    Mike C. Fletcher, Sep 25, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. F. GEIGER
    Replies:
    0
    Views:
    949
    F. GEIGER
    Aug 16, 2004
  2. Szucs Szabolcs Laszlo

    py2exe with opengl

    Szucs Szabolcs Laszlo, Oct 18, 2004, in forum: Python
    Replies:
    1
    Views:
    365
    Thomas Heller
    Oct 18, 2004
  3. python
    Replies:
    3
    Views:
    1,883
    Simon Brunning
    May 22, 2006
  4. Chris Spencer

    Re: [Py2exe-users] py2exe 0.6.9 released

    Chris Spencer, Nov 17, 2008, in forum: Python
    Replies:
    3
    Views:
    599
    Pascal
    Dec 8, 2008
  5. Mark Hammond

    RE: [Py2exe-users] py2exe 0.6.9 released

    Mark Hammond, Nov 17, 2008, in forum: Python
    Replies:
    0
    Views:
    479
    Mark Hammond
    Nov 17, 2008
Loading...

Share This Page