I've recently started learning openGL programming. However, when I compile the program, it can't detect the header file "gltk.h", causing numerous functions not to be found. I have looked for a library containing these files, but the closest I got was a site with broken links claiming it had an rpm that probably didn't work. Either way, I'm at a loss. I'm sure there's something simple that I'm just not seeing, so I'm asking if anyone could point me in the right directon. As a note, I'm using Slackware 10.2 and kernel 2.6.14.4. I have also included the error message just in case I have a completely wrong idea of what's going on.
I am using the exact code from the following tutorial site:
http://www.eecs.tulane.edu/www/Terry...L%20Primitives
Code:
user@computer:~$ gcc -o Primitives Primitives.c -lX11 -lMesaGL -lMesaGLU -lMesatk -lm
test.c:19:18: gltk.h: No such file or directory
test.c: In function `expose':
test.c:24: error: `GL_COLOR_BUFFER_BIT' undeclared (first use in this function)
test.c:24: error: (Each undeclared identifier is reported only once
test.c:24: error: for each function it appears in.)
test.c: In function `reshape':
test.c:30: error: `GLint' undeclared (first use in this function)
test.c:30: error: syntax error before "width"
test.c:34: error: `GL_PROJECTION' undeclared (first use in this function)
test.c:44: error: `GL_MODELVIEW' undeclared (first use in this function)
test.c:47: error: `GL_COLOR_BUFFER_BIT' undeclared (first use in this function)
test.c: At top level:
test.c:50: error: syntax error before "key_down"
test.c:50: error: syntax error before "GLenum"
test.c: In function `key_down':
test.c:52: error: `key' undeclared (first use in this function)
test.c:52: error: `TK_ESCAPE' undeclared (first use in this function)
test.c:52: error: `TK_q' undeclared (first use in this function)
test.c:52: error: `TK_Q' undeclared (first use in this function)
test.c: In function `draw':
test.c:67: error: `GL_LINES' undeclared (first use in this function)
test.c:89: error: `GL_LINE_STRIP' undeclared (first use in this function)
test.c:100: error: `GL_LINE_LOOP' undeclared (first use in this function)
test.c:111: error: `GL_POLYGON' undeclared (first use in this function)
test.c:122: error: `GL_QUADS' undeclared (first use in this function)
test.c:133: error: `GL_QUAD_STRIP' undeclared (first use in this function)
test.c:144: error: `GL_TRIANGLES' undeclared (first use in this function)
test.c:155: error: `GL_TRIANGLE_STRIP' undeclared (first use in this function)
test.c:166: error: `GL_TRIANGLE_FAN' undeclared (first use in this function)
test.c: In function `main':
test.c:185: error: `GL_FALSE' undeclared (first use in this function)