Reputation: 245
I'm having some trouble configuring eclipse correctly with OpenGL. I followed several tutorials online, but none seemed to solve the problem. What I have done is created a new project, and on right-click: properties->C/C++ build->Settings->Cross G++ Linker. Here I added the libraries 'glut' and 'GLU'. But whatever code I try to run, the compiler seems completely unaware of OpenGL completely. I also tried adding 'opengl' to the libraries, but this didn't help either. I have a working OpenGL/glut/GLU installation on my laptop, as I was previously using a text editor with the terminal to compile the code.
Upvotes: 1
Views: 3240
Reputation: 116
Make sure glut is installed in your computer, you can use the following command to do it
sudo apt-get install freeglut3-dev
Upvotes: 0
Reputation: 162184
You must install the OpenGL development files in Ubuntu first. Package name is libgl1-mesa-dev
. And while you're at it, you might want to install some other convenience libraries as well. This should cover your immediate OpenGL development needs.
sudo apt-get install \
libgl1-mesa-dev \
libglu1-mesa-dev \
libgles1-mesa-dev \
libgles2-mesa-dev \
libglew-dev \
freeglut3-dev \
libglfw-dev
Upvotes: 1