opengl & linux

Started by
17 comments, last by cody 22 years, 5 months ago
Ok, you need to link it against more libraries than just GL.

Try this :

gcc -lXext -lXmu -lXi -lX11 -lGL -o yourprogram source.c

You might also need -lGLU if you''re using GLU, and -lm, depending on your program.

Hope this helps.
Advertisement
Ah and create a symlink to your gl libraries.

su
password:
cd /usr/lib
ln -s libGL.so.1.0.1541.nv_glx libGL.so
yeah, it seams your symlink works, thanks!
About the nvidia OpenGL headers should you move them to your normal GL include directory if you want to use them.
quote:.lib=.a and .so=.dll

Actually .o is also a kind of lib file under Linux. .a files are simply archives of .o files.

.o - object file (lib)
.a - archive file (lib)
.so - shared object file (dll and lib)
I installed too linux, Mandrake 8.1 and installation was very very easy.

I have a problem with KDevelop. I can''t create new projects/files (lol). The new button on toolbar and menu are grayed.
Maybe there''s something I don''t know yet about Linux
Hepl me to create new project/files.
quote:Original post by stefu
I have a problem with KDevelop. I can''t create new projects/files (lol). The new button on toolbar and menu are grayed.

That''s odd. Not much lost though, I didn''t like KDevelop much when I tried it (it is overly complex for simple projects). If you get the time, read a tutorial on makefiles (they really aren''t as hard to do as they seem), maybe you''ll like using the command line as much as I do? (Anjuta and ETerm are all I need )

[Resist Windows XP''s Invasive Production Activation Technology!]
No worry I'll do it command line

I just found that I need to first make new project: Project -> ApplicationWizard. I was too common with VisualC ad looked just File -> New

edit:

Actually I found after a moment KDevelop complex, I'll not use it.

PS. Where to get glu.h for linux?

more edit:

Shall I ask where to put all sources, libraries ... in linux, how to organize all. Are there any rules/considerations so that whenever I get a code and it requires some libraries and header files to compile, it comples without any changes? Sorry for dumb question, but I'm quite first timer with Linux

Edited by - stefu on October 31, 2001 9:25:39 AM
Hmm, I found KDevelope to be outstanding. The new project button is in the top/center of the main screen. Use what ever you find more comfortable but personally I found it refreshing to see there is a comparable setup to MSVC++(which I also liked)

This topic is closed to new replies.

Advertisement