Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is gl3w available as a library by default in Ubuntu? #58

Closed
ghost opened this issue Jun 11, 2018 · 5 comments
Closed

Is gl3w available as a library by default in Ubuntu? #58

ghost opened this issue Jun 11, 2018 · 5 comments

Comments

@ghost
Copy link

ghost commented Jun 11, 2018

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?

@ikskuh
Copy link

ikskuh commented Jun 11, 2018

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)

@ghost
Copy link
Author

ghost commented Jun 11, 2018

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

@tombsar
Copy link
Collaborator

tombsar commented Jun 11, 2018

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.

@ghost
Copy link
Author

ghost commented Jun 11, 2018

@tombsar: Thank you for the clear reply.

@tombsar
Copy link
Collaborator

tombsar commented Jun 20, 2018

Closing this. Please reopen if you have further questions.

@tombsar tombsar closed this as completed Jun 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants