[GRASSLIST:2888] Re: Nviz problem & mac

Glynn Clements glynn.clements at virgin.net
Fri Jan 11 09:13:23 EST 2002


Quim Soler i Subils wrote:

> I've a problem compiling nviz2.2 (grass5.0pre2) on Mac OS X. It fails
> when trying to compile the glx's (_TkGLX_Init, _glXChooseVisual,
> _glXCreateContext, _glXDestroyContext, _glXGetConfig, _glXMakeCurrent,
> _glXQueryExtension, _glXQueryServerString, _glXSwapBuffers, _glXUseXFont).
> 
> This is the OpenGL section of my "head.powerpc-apple-darwin1.3.3" file
> 
>  #openGL files for NVIZ/r3.showdspf
> OPENGLINC = -I/usr/local/include/GL -I/usr/include -I/usr/X11r6/include
> OPENGLwINC = -I/usr/local/include/GL -I/usr/include -I/usr/X11R6/include
> OPENGLLIB =
> -L/system/library/frameworks/opengl.framework/versions/A/libraries -lGL
> OPENGLULIB =
> -L/system/library/frameworks/opengl.framework/versions/A/libraries -lGLU
>  LGLWM = -lGLw
> OPENGL32 =
> 
> /System/library/frameworks/opengl.framework/versions/A/Libraries is the
> path of the directory where de OpenGL libraries on Mac OS live. When I
> found this problem I compiled the Mesa libraries (and I put them in
> /usr/local/lib) but there was no sucess on compiling nviz.
> 
> Do you kwnou what I'am doing wrong? Where must I search these glx
> undefined symbols? In OpenGL? Or they are specific of Mesa?

They are specific to X11. Your OpenGL library needs to be one targeted
to X, and not to the native MacOS graphics system.

XFree86 4.* includes OpenGL libraries in /usr/X11R6/lib; those should
work.

The core OpenGL API doesn't include any functions for setting up or
controlling the rendering environment, as the details of such
functions are tied to the graphics/windowing system. Each platform has
its own functions to do this: glX* on X11, wgl* on Windows, agl* on
MacOS, pgl* on OS/2.

The TOGL (Tcl/Tk OpenGL) code used by NVIZ only supports X11 and
Windows. If you have a Unix version of Tcl/Tk and a version of X11
with OpenGL support, that should be sufficient. But the code won't
currently work with native MacOS versions of Tcl/Tk or OpenGL.

-- 
Glynn Clements <glynn.clements at virgin.net>



More information about the grass-user mailing list