Everything undefined

I am very new to OpenGL and Linux, so I may have made an obvious mistake, but:

I installed Mesa-5.0 on Redhat 8.0 so that I could start including OpenGL in my programs. I used the standard configure,make,make install routine logged in as the root. No error listed on the install.
But every GL function in every program I try produces an undefined reference error. What am I doing wrong?

You’re probably not linking with the correct libraries.

gcc … -lGL -lGLU -lglut …

You might have to fiddle with the order. I don’t remember if you need to link glut first or last.

Btw, you can use the makefile I posted here for your projects.

Thanks. That did the trick!

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.