help needed: glut on irix


I started programming with Glut on MacOS X and now want to do the same on my Onyx2, but I seem to be too stupid or missing something to get it to work.

I have installed the opengl header files in the correct directories (/usr/include), I have installed the GLUT 3.7 release from the SGI Freeware page, and I have downloaded the example scripts from the OpenGL Redbook, which compile fine on my OS X box, but I just can’t get it to work under IRIX. I am using gcc, and when I try to compile, I get dozens of linking errors like “Unresolved text symbol “glClear” – 1st referenced by /var/tmp/cc7mg61a.o” (does this for every glut or opengl function)

Do I have to copy any other files, any precompiled modules? Anything?

the compiler finds the header files, because if I remove them, he - correctly - tells me that he can’t include the files and begins to complain about undeclared vars.

Do I have to set a special flag in gcc to compile GLUT code?

Any help, a link to a tutorial, anything is greatly appreciated.

many thanx in advance!


glClear is an OpenGL call.

Are you linking the OpenGL libs?

I use …

-I/usr/local/include/GLUT/ -L/usr/local/lib/ -lglut -lGL -lGLU -lXmu -lXext -lX11 -lm

SGI O2, IRIX 6.5.n


Thanx for the answer, it helped a lot, but now I am having a new problem:

it seems like my OpenGL Libraries are 32 bit, though I point the compiler to the 64 bit directory…I installed them from the Developer Libraries CD from IRIX 6.5, on IRIX64.

I guess I have to search a 64 bit OpenGL Library now…