13:42 denery: hi, this channel was linked on Mesa's gitlab page and I am not sure if it's an appropriate place to ask this. I have an application which uses eglInitialize call under the hood and it works just fine on X11 but fails on Wayland (dwl tiling manager) with EGL_NOT_INITIALIZED error. The same thing happens for the peglgears.c Mesa demo program which uses the same function. I have an
13:42 denery: old AMDGPU card, how do I debug this issue to find the cause and fix it? Most resources online about this error link to issues with nvidia cards, but it's not my case, and I am lost as to what causes it.
14:02 MrCooper: denery: can you pastebin the output of wayland-info & eglinfo?
14:06 denery: wait a sec, let me log into a wayland session
14:22 denery: eglinfo: https://pastebin.com/1GxmGHAf wayland-info: https://pastebin.com/TSRXvtnr
14:34 MrCooper: the X11 platform fails to initialize, no Xwayland?
14:35 MrCooper: my guess would be that Mesa was built with x11 as the default platform (egl-native-platform build option), and the apps don't explicitly choose another platform
14:39 denery: I use gentoo, I think that could have happened
14:39 denery: I have xwayland tho
14:39 denery: at least it's listed in the /var/lib/portage/world
14:51 MrCooper: rootless Xwayland needs to be started by the Wayland compositor, maybe dwl doesn't (by default)
14:52 denery: I am curious, what's the way to specify in the code for application to choose between platforms in egl?
14:53 MrCooper: the simplest way might be to pass a platform-specific display handle instead of EGL_DEFAULT_DISPLAY to eglGetDisplay
14:55 MrCooper: looks like eglGetPlatformDisplay is needed instead
14:56 denery: I see
14:56 denery: oh, it seems I compiled dwl without xwayland support, it explains it
15:01 denery: I recompiled dwl with the xwayland support, let me reboot again to see if something changes
15:03 denery: it works, thanks
15:06 MrCooper: no worries
17:58 vsyrjala: lucaceresoli: your devm bridge stuff broke the build. based on a cursory glance CONFIG_OF=n is when it blows up