Reputation: 26652
I want to compile an OpenGL program but I don't have the necessary headers. Maybe you know how to get these?
#include <GL/glx.h> /* this includes the necessary X headers */
#include <GL/gl.h>
#include <X11/X.h> /* X11 constant (e.g. TrueColor) */
#include <X11/keysym.h>
It's the OpenGL example from the Codeblocks IDE that I'm trying to get running under ubuntu .
Upvotes: 0
Views: 3215
Reputation: 475
I installed the following packages:
and all their dependencies, after which I can directly include the headers you mentioned in my C program.
If you want to know the paths of these headers, do locate gl.h
, locate glx.h
, locate X.h
and locate keysym.h
. Be sure to sudo updatedb
before you use locate
.
Upvotes: 1
Reputation: 798486
The OpenGL headers are part of Mesa, and the X11 headers are in Xorg's protocol development package.
Upvotes: 3