Jump to content

  • Log In with Google      Sign In   
  • Create Account

Using GLUT


Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
5 replies to this topic

#1   Members   

830
Like
0Likes
Like

Posted 20 January 2013 - 12:21 PM

Hey everyone, just forced myself to use Linux Mint and I want to start coding, but having trouble starting up GLUT. Not really worked with Linux much, but i've grasped the concept that I need to load it through the console.

 

Everyone is telling me to link the libraries to the usr/includes folder but even though freeGlut is installed I can't find them. Any help would be appreciated.

 

P.S. I'm trying to use OpenGL and C++.


If you get near a point, make it!

#2   Members   

3102
Like
0Likes
Like

Posted 20 January 2013 - 02:30 PM

I assume you're coming from windows?  One nice thing to note about the linux environment is that there's often a lot stricter use of the defined folder structure. If you've used apt-get or another package manager to install GLUT, then gcc will automatically know where the libs are, and the includes (should be #include <GL/glut.h>). You just need to add the -lglut to your compile to link it (g++ foo.cpp -lglut)



#3   Members   

2306
Like
0Likes
Like

Posted 20 January 2013 - 02:48 PM

Also make sure that the glut "developer stuff" is installed (static libs/headers).

(I use Red Hat so I am not sure of the exact command)

try...

'apt-get install glut-dev'

...or...

'apt-get install freeglut-dev'

Basically, most Linux packagers split software into runtime, development and documentation packages so you just needed the dev packages.

Edited by Karsten_, 20 January 2013 - 02:50 PM.

http://tinyurl.com/shewonyay - Thanks so much for those who voted on my GF's Competition Cosplay Entry for Cosplayzine. She won! I owe you all beers :)

Mutiny - Open-source C++ Unity re-implementation.
Defile of Eden 2 - FreeBSD and OpenBSD binaries of our latest game.

#4   Members   

830
Like
0Likes
Like

Posted 20 January 2013 - 05:00 PM

Cheers guys, really appreciate the help.


If you get near a point, make it!

#5   Members   

830
Like
0Likes
Like

Posted 20 January 2013 - 05:07 PM

Also make sure that the glut "developer stuff" is installed (static libs/headers).

 

freeglut dev wasnt installed, that was the problem. Didn't realise I needed both!


If you get near a point, make it!

#6   Members   

8954
Like
0Likes
Like

Posted 20 January 2013 - 05:31 PM

That's what the dev libraries are for. If you need it for coding something, download the dev one too.


"I AM ZE EMPRAH OPENGL 3.3 THE CORE, I DEMAND FROM THEE ZE SHADERZ AND MATRIXEZ"

 

My journals: dustArtemis ECS framework and Making a Terrain Generator





Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.