octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: OpenGL error with mxe-octave build


From: Philip Nienhuis
Subject: Re: OpenGL error with mxe-octave build
Date: Thu, 26 Jun 2014 09:40:08 -0700 (PDT)

John W. Eaton wrote
> I'm seeing the following error when trying to build the current default 
> branch for Windows with mxe-octave.  Is it just me, or is anyone else 
> hitting this error?  If it works for others, am I missing some package? 
>   I did just try to update to the latest sources by creating a 
> 4.1.0+.tar.gz file from the current default branch and dropping it in to 
> an old build tree, so maybe something that needs to be updated was not? 
>   I can try starting from a completely clean mxe-octave build tree and 
> see if that avoids the problem but it will take a while for a complete 
> build to finish so I thought I would ask first.
> 
> jwe
> 
> 
> libtool: compile:  i686-w64-mingw32-g++ -DHAVE_CONFIG_H -I. 
> -I/scratch/jwe/src/m
> xe-octave-hg/tmp-octave/octave-4.1.0+/libinterp -I.. 
> -I/scratch/jwe/src/mxe-octa
> ve-hg/tmp-octave/octave-4.1.0+/liboctave/cruft/misc 
> -I/scratch/jwe/src/mxe-octav
> e-hg/tmp-octave/octave-4.1.0+/liboctave/array -I../liboctave/numeric 
> -I/scratch/
> jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/liboctave/numeric 
> -I../liboctave/
> operators 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/liboctave/op
> erators 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/liboctave/syst
> em 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/liboctave/util 
> -I/s
> cratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/octave-value 
> -I/
> scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/operators 
> -Ipar
> se-tree 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/pars
> e-tree -Icorefcn 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libin
> terp/corefcn -I../libgnu 
> -I/scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.
> 0+/libgnu -I/scratch/jwe/src/mxe-octave-hg/usr/i686-w64-mingw32/include 
> -I/scrat
> ch/jwe/src/mxe-octave-hg/usr/i686-w64-mingw32/include/freetype2 
> -I/scratch/jwe/s
> rc/mxe-octave-hg/usr/i686-w64-mingw32/include 
> -I/scratch/jwe/src/mxe-octave-hg/u
> sr/i686-w64-mingw32/include/freetype2 
> -I/scratch/jwe/src/mxe-octave-hg/usr/i686-
> w64-mingw32/include 
> -I/scratch/jwe/src/mxe-octave-hg/usr/i686-w64-mingw32/includ
> e -mieee-fp -Wall -W -Wshadow -Wold-style-cast -Wformat -Wpointer-arith 
> -Wwrite-strings -Wcast-align -Wcast-qual -g -O2 -pthread -MT 
> corefcn/corefcn_libcorefcn_la-hess.lo -MD -MP -MF 
> corefcn/.deps/corefcn_libcorefcn_la-hess.Tpo -c 
> /scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/corefcn/hess.cc
>  
>   -DDLL_EXPORT -DPIC -o corefcn/.libs/corefcn_libcorefcn_la-hess.o
> /scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/corefcn/gl-render.cc:
>  
> In member function 'virtual void opengl_renderer::init_gl_context(bool, 
> const Matrix&)':
> /scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/corefcn/gl-render.cc:647:17:
>  
> error: 'GL_MULTISAMPLE' was not declared in this scope
>         glEnable (GL_MULTISAMPLE);
>                   ^
> /scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/corefcn/gl-render.cc:649:22:
>  
> error: 'GL_SAMPLE_BUFFERS' was not declared in this scope
>         glGetIntegerv (GL_SAMPLE_BUFFERS, &iMultiSample);
>                        ^
> /scratch/jwe/src/mxe-octave-hg/tmp-octave/octave-4.1.0+/libinterp/corefcn/gl-render.cc:650:22:
>  
> error: 'GL_SAMPLES' was not declared in this scope
>         glGetIntegerv (GL_SAMPLES, &iNumSamples);
>                        ^

I reported this some weeks ago on the maintainers ML.
Rik advised (w/o much detail) to

#include <GL/glext.h>

(turned out it was needed in gl-render.h)
and that worked for me.
(In fact I had to fix this very issue again yesterday as I wiped my octave
default hg clone to start all over :-) )

My 4.1.0+ gl-render.h #defines from 4 weeks or so ago look like this (but
I'm not sure I included glext.h at the right place, that's probably why I
haven't produced a patch yet):


#if !defined (octave_gl_render_h)
#define octave_gl_render_h 1

#ifdef HAVE_WINDOWS_H
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#endif

#ifdef HAVE_GL_GL_H
#include <GL/gl.h>
#ifdef HAVE_WINDOWS_H
#include <GL/glext.h>
#endif
#elif defined HAVE_OPENGL_GL_H || defined HAVE_FRAMEWORK_OPENGL
#include <OpenGL/gl.h>
#endif

#ifdef HAVE_GL_GLU_H
#include <GL/glu.h>
#elif defined HAVE_OPENGL_GLU_H || defined HAVE_FRAMEWORK_OPENGL
#include <OpenGL/glu.h>
#endif

#include "graphics.h"
#include "txt-eng-ft.h"


I think yesterday on my build box I put the glext.h line a bit higher up
(can't check now).

Philip



--
View this message in context: 
http://octave.1599824.n4.nabble.com/OpenGL-error-with-mxe-octave-build-tp4665075p4665080.html
Sent from the Octave - Maintainers mailing list archive at Nabble.com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]