Including GLEE after GLUT

I have many source files which include glut.h that I compile and link to in my makefile. The problem is, when I try to include GLee.h in my “main” source file, it complains

error: #error gl.h included before glee.h

Is there any way to fix this without going back and including glee everywhere I include glut?

Thanks,
Dave

You could, say, create a header that includes everything in the right order, then include that everywhere.

you could hack your way through. before including GLEE undef the GL_H define kindof. beware! hacky solution but should work.

#ifdef GL_H
#undef GL_H
#endif

otherwise just use your IDE’s find and replace feature to change include strings.

You don’t need a hack, everywhere you need glut, just include glee before. This way, you are sure that glee is included before glut.