nigels-com / glew

The OpenGL Extension Wrangler Library
Other
2.58k stars 609 forks source link

Built with SYSTEM=linux-egl, glew apps crash on NVIDIA #315

Open badshah400 opened 2 years ago

badshah400 commented 2 years ago

On openSUSE, we have recently switched to building glew with EGL support. This however leads to crashes for apps dependent on glew on NVIDIA graphics. Starting visualinfo fails, for example, with the following error message:

Error [main]: glewInit failed: Missing GL version

Attaching the output of glewinfo here: glewinfo.txt.gz.

Here is the output of glxinfo: glxinfo.txt.gz

OTOH we cannot simply disable building glew with EGL support, since it causes wxWidgets 3.1.5 apps to crash (on all systems). See, for example, this Hugin bug.

Thanks.

nigels-com commented 2 years ago

Context here is that OpenSUSE is switching to Wayland by default?

badshah400 commented 2 years ago

Context here is that OpenSUSE is switching to Wayland by default?

We did that a while ago (at least for GNOME on Tumbleweed) already except on NVIDIA systems.

For me the more narrow goal is to avoid wxWidgets apps that use glew from crashing after wxWidgets 3.1.5 started using EGL by default for better native performance on Wayland. Unless we build glew with EGL support, apps like hugin now crash (see bug report linked to in my description). If we do build glew with EGL, it seems everything else (like visualinfo) crashes. I just discovered that visualinfo crashes also on my laptop with Intel graphics, so this may not have anything to do with NVIDIA specifically after all.

nigels-com commented 2 years ago

Interesting. Thanks for the additional information.

frispete commented 2 years ago

Let me add, that the Blender 2.93.3 build fails with interesting errors (depending on the used compiler/ld), when using SYSTEM_GLEW. I've collected some related data here:

https://devtalk.blender.org/t/building-blender-2-93-3-with-system-glew-fails/20090

jwinarske commented 2 years ago

I get the same runtime error on Ubuntu 20.04.4 LTS with glew-2.2.0.