This is the kind of thing that should go under Developers->OpenGL on Macintosh.
You can use XCode, but there are a couple tweaks to most available tutorials:
Add the framework OpenGL.framework to the target
Instead of including <GL/gl.h>, include <OpenGL/gl.h> ( include it from the framework).
If you’re going to use GLUT, use the GLUT framework (add it to the project, include from there). You can also use Cocoa and the NSOpenGLView. Check out the docs on that, and hopefully you should be all set.