skaslev/gl3w

Is gl3w available as a library by default in Ubuntu?

Closed this issue · 5 comments

For now, we have to add gl3w.c into the project as a source file. It is annoying sometimes if we have many an OpenGL projects to create because we have to repeat this adding work for each new project and the compiler has to compile it again and again, generating exactly the same binary code which resides in every executible. GLEW, on the other hand, is a library available by default in Ubuntu. All we need to do to load OpenGL functions is add a linking flag for it. Then all the functions in GLEW are ready to use. Further, only one copy of memory and file system space is consumed for GLEW. Is this the case for gl3w? That is, is gl3w available as a (shared) library in Ubuntu by default?

If you require a shared library that provides the functionality of gl3w, just compile it with
gcc -shared -fPIC -o libgl3w.so -I ../include/ gl3w.c, then reference the folder of libgl3w.so in your projects.

I really like gl3w for not beeing a shared library, as it is small enough to not be a burden when used for static linking, also it removes a dependency so i don't require gl3w to be installed on other machines (with outdated versions or similar)

I'm afraid you misunderstand my question. I'm not asking what you are trying to answer.

Ubuntu does not currently package gl3w; someone would need to take responsibility for creating and maintaining the package at Ubuntu's side. You can install it locally if you like, as MasterQ32 explained.

@tombsar: Thank you for the clear reply.

Closing this. Please reopen if you have further questions.