[PyOpenGL-Users] Problem with PyOpenGL support under cygwin: ctypes cannot find GL lib(?)
Brought to you by:
mcfletch
From: Martin F. <fe...@in...> - 2007-02-07 15:15:43
|
Hi, in trying to get my python OpenGL application to run under cygwin, I installed the PyOpenGL package, version 3.0.0a5 for python 2.4, and ctypes 1.0.1. For one thing, could it be the .egg is broken? I keep getting 225> easy_install PyOpenGL-3.0.0a5-py2.4.egg Processing PyOpenGL-3.0.0a5-py2.4.egg Traceback (most recent call last): File "/usr/bin/easy_install", line 7, in ? sys.exit( File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 1670, in m ain with_ei_usage(lambda: File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 1659, in w ith_ei_usage return f() File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 1674, in < lambda> distclass=DistributionWithoutHelpCommands, **kw File "/tmp/python.340/usr/lib/python2.4/distutils/core.py", line 149, in setup File "/tmp/python.340/usr/lib/python2.4/distutils/dist.py", line 946, in run_commands File "/tmp/python.340/usr/lib/python2.4/distutils/dist.py", line 966, in run_command File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 211, in ru n self.easy_install(spec, not self.no_deps) File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 427, in ea sy_install return self.install_item(None, spec, tmpdir, deps, True) File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 471, in in stall_item dists = self.install_eggs(spec, download, tmpdir) File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 619, in in stall_eggs return [self.install_egg(dist_filename, tmpdir)] File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 670, in in stall_egg dist = self.egg_distribution(egg_path) File "/usr/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py", line 661, in eg g_distribution metadata = EggMetadata(zipimport.zipimporter(egg_path)) zipimport.ZipImportError: not a Zip file: 'PyOpenGL-3.0.0a5-py2.4.egg' Well, anyway, the .zip file worked. Now whenever I try to run an OpenGL application, the following happens: Traceback (most recent call last): File "GLvis.py", line 8, in ? from OpenGL.GL import * File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/GL/__init__.py", line 2, in ? from OpenGL.raw.GL import * File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/raw/GL/__init__.py", line 6, in ? from OpenGL.raw.GL.constants import * File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/raw/GL/constants.py", line 7, in ? from OpenGL import platform, arrays File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/platform/__init__.py", line 24, in ? from OpenGL.platform.glx import * File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/platform/glx.py", line 29, in ? mode=ctypes.RTLD_GLOBAL File "/usr/lib/python2.4/site-packages/PyOpenGL-3.0.0a5-py2.4.egg/OpenGL/platform/ctypesloader.py", line 37, in loadLibrary return dllType( name, mode ) File "/usr/lib/python2.4/site-packages/ctypes/__init__.py", line 312, in __init__ self._handle = _dlopen(self._name, mode) OSError: No such file or directory When this happens, self._name is "GL" and mode is 4. It would seem as though somehow the GL library is not registered(?) with python? I'm at a loss here - can anybody give me a hint? Has there been any successful attempt at running PyOpenGL under cygwin? I append a cygwin configuration dump. Thanks, Martin |