more wxPython compile errors?

Hm.. I have PyOpenGl installed (2.0.0.44) as well as the necessary GL
headers from my NVIDIA driver setup. I continue to have compile errors
relating to gl code (see below).
This is only the beginning of the errors that I get from compilation.
It seems like I'm missing something obvious. The commands I ran are
these:
./configure --with-gtk --prefix=/usr --enable-rpath=/usr/lib
--enable-geometry --enable-optimise --enable-debug_flag --enable-gtk2
--enable-unicode --with-opengl &&
make && make install &&
cd wxPython &&
python setup.py WXPORT=gtk2 UNICODE=1 build install

My enviroment is Python 2.2.3, PyOpenGL 2.0.0.44, gtk 2.2, and wxPython
2.4.1.2. The GL headers are from the NVIDIA_GLX package

-- Thanks! Jeff
contrib/glcanvas/gtk/glcanvas.cpp: In function `void*
   SwigwxGLContextTowxObject(void*)':
contrib/glcanvas/gtk/glcanvas.cpp:99: `wxGLContext' undeclared (first
use this
   function)
contrib/glcanvas/gtk/glcanvas.cpp:99: (Each undeclared identifier is
reported
   only once for each function it appears in.)
contrib/glcanvas/gtk/glcanvas.cpp:99: `src' undeclared (first use this
   function)
contrib/glcanvas/gtk/glcanvas.cpp:101: syntax error before `)' token
contrib/glcanvas/gtk/glcanvas.cpp: In function `PyObject*
   _wrap_new_wxGLContext(PyObject*, PyObject*, PyObject*)':
contrib/glcanvas/gtk/glcanvas.cpp:109: `_result' undeclared (first use
this
   function)
contrib/glcanvas/gtk/glcanvas.cpp:111: `wxGLCanvas' undeclared (first
use this
   function)

Jeff Hodges wrote:

Hm.. I have PyOpenGl installed (2.0.0.44) as well as the necessary GL
headers from my NVIDIA driver setup. I continue to have compile errors
relating to gl code (see below). This is only the beginning of the errors that I get from compilation. It seems like I'm missing something obvious. The commands I ran are
these: ./configure --with-gtk --prefix=/usr --enable-rpath=/usr/lib

BTW: If you are using the standard prefix then there is no need for the rpath...

--enable-geometry --enable-optimise --enable-debug_flag --enable-gtk2
--enable-unicode --with-opengl &&

Take a look at the output to configure to ensure that it found everyting it needed for OpenGL. I think that NVIDIA only supplies one of the components, you may need to install one or more Mesa -devel packages to get the headers for the rest of it.

Also, check that libwx_gtk_gl* was actually built.

make && make install && cd wxPython && python setup.py WXPORT=gtk2 UNICODE=1 build install

My enviroment is Python 2.2.3, PyOpenGL 2.0.0.44, gtk 2.2, and wxPython
2.4.1.2. The GL headers are from the NVIDIA_GLX package

If the libwx_gtk_gl* lib was built then there is one other potential problem. I'm a little fuzzy on the details but there was[*] a bug in configure that assumed that all the GL headers were in the same location, but NVIDIA installs theirs in a different (but still standard) location so you end up with some GL headers in /usr/include and others in /usr/X11R6/include. IIRC the way I got around this was to make symlinks in /usr/include to the appropriate files in /usr/X11R6/include.

* It may have only been fixed for 2.5 though.

Or if you don't need OpenGL you can just disable it in the setup.py file.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Also, check that libwx_gtk_gl* was actually built.

Do libwx_gtk2ud-2.4.so.0.0.0 and libwx_gtk2ud_gl-2.4.so.0.0.0 count?
:slight_smile:

If the libwx_gtk_gl* lib was built then there is one other potential
problem. I'm a little fuzzy on the details but there was[*] a bug in
configure that assumed that all the GL headers were in the same
location, but NVIDIA installs theirs in a different (but still standard)
location so you end up with some GL headers in /usr/include and others
in /usr/X11R6/include. IIRC the way I got around this was to make
symlinks in /usr/include to the appropriate files in /usr/X11R6/include.

I have /usr/include/GL as a symlink to /usr/X11R6/include
lrwxrwxrwx 1 root root 21 2003-03-04 01:51
/usr/include/GL -> /usr/X11R6/include/GL

* It may have only been fixed for 2.5 though.

Or if you don't need OpenGL you can just disable it in the setup.py
file.

I do need it unfortunately :frowning:
I did find one oddity though, the GL headers were not installed for some
reason though it appeared otherwise (long story). I reinstalled the
headers et al. but instead of beginning with the GL header not found
error, I am finding

contrib/glcanvas/gtk/glcanvas.cpp:99: `wxGLContext' undeclared (first
use this
   function)

and

contrib/glcanvas/gtk/glcanvas.cpp:435: syntax error before `)' token
contrib/glcanvas/gtk/glcanvas.cpp: In function `void*
   SwigwxGLCanvasTowxEvtHandler(void*)':

as well as a few other of these same syntax errors in function
PyObject. I also noted

contrib/glcanvas/gtk/glcanvas.cpp: In function `void initglcanvasc()':
contrib/glcanvas/gtk/glcanvas.cpp:924: `WX_GL_RGBA' undeclared (first
use this
   function)
and other WX_GL_* undeclared errors. Now what has this foolish user
done? Thanks!
  -- Jeff

···

On Fri, 2003-07-18 at 13:53, Robin Dunn wrote:

Jeff Hodges wrote:

···

On Fri, 2003-07-18 at 13:53, Robin Dunn wrote:

Also, check that libwx_gtk_gl* was actually built.

Do libwx_gtk2ud-2.4.so.0.0.0 and libwx_gtk2ud_gl-2.4.so.0.0.0 count?
:slight_smile:

If the libwx_gtk_gl* lib was built then there is one other potential problem. I'm a little fuzzy on the details but there was[*] a bug in configure that assumed that all the GL headers were in the same location, but NVIDIA installs theirs in a different (but still standard) location so you end up with some GL headers in /usr/include and others in /usr/X11R6/include. IIRC the way I got around this was to make symlinks in /usr/include to the appropriate files in /usr/X11R6/include.

I have /usr/include/GL as a symlink to /usr/X11R6/include
lrwxrwxrwx 1 root root 21 2003-03-04 01:51
/usr/include/GL -> /usr/X11R6/include/GL

* It may have only been fixed for 2.5 though.

Or if you don't need OpenGL you can just disable it in the setup.py
file.

I do need it unfortunately :frowning:
I did find one oddity though, the GL headers were not installed for some
reason though it appeared otherwise (long story). I reinstalled the
headers et al. but instead of beginning with the GL header not found
error, I am finding

contrib/glcanvas/gtk/glcanvas.cpp:99: `wxGLContext' undeclared (first
use this function)

Did you re-configure/build/install wxGTK? You may need to remove the config.cache file first.

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

so... um.. you're awesome.. thanks!

···

On Mon, 2003-07-21 at 18:15, Robin Dunn wrote:

Jeff Hodges wrote:
> On Fri, 2003-07-18 at 13:53, Robin Dunn wrote:
>
>>Also, check that libwx_gtk_gl* was actually built.
>
> Do libwx_gtk2ud-2.4.so.0.0.0 and libwx_gtk2ud_gl-2.4.so.0.0.0 count?
> :slight_smile:
>
>
>>If the libwx_gtk_gl* lib was built then there is one other potential
>>problem. I'm a little fuzzy on the details but there was[*] a bug in
>>configure that assumed that all the GL headers were in the same
>>location, but NVIDIA installs theirs in a different (but still standard)
>>location so you end up with some GL headers in /usr/include and others
>>in /usr/X11R6/include. IIRC the way I got around this was to make
>>symlinks in /usr/include to the appropriate files in /usr/X11R6/include.
>
> I have /usr/include/GL as a symlink to /usr/X11R6/include
> lrwxrwxrwx 1 root root 21 2003-03-04 01:51
> /usr/include/GL -> /usr/X11R6/include/GL
>
>
>>* It may have only been fixed for 2.5 though.
>>
>>Or if you don't need OpenGL you can just disable it in the setup.py
>> file.
>
> I do need it unfortunately :frowning:
> I did find one oddity though, the GL headers were not installed for some
> reason though it appeared otherwise (long story). I reinstalled the
> headers et al. but instead of beginning with the GL header not found
> error, I am finding
>
> contrib/glcanvas/gtk/glcanvas.cpp:99: `wxGLContext' undeclared (first
> use this
> function)

Did you re-configure/build/install wxGTK? You may need to remove the
config.cache file first.