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
2.0.16: (Wayland without X) SDL_CreateWindow: failed to create an EGL window surface #4650
Comments
CC @caramelli, I believe this commit was specifically to allow X-less Wayland support. |
Do you have any X libraries in stalled on your system, or you running 100% with nothing X related installed? I am saying this because SDL2 is still linked to X libraries even if you are using Wayland. Also, your sample program launched for me on KDE Wayland, which does requires X libraries even on Wayland. |
I do not have X libraries in my system and SDL 2.0.14 builds and works without linking to them. Here is a full list of packages in my system: |
sdl2.build.log |
sdl2.build.2.0.16.log < -- Performing Test HAVE_VIDEO_OPENGL
< -- Performing Test HAVE_VIDEO_OPENGL - Failed
> -- Performing Test HAVE_VIDEO_OPENGL_GLX
> -- Performing Test HAVE_VIDEO_OPENGL_GLX - Failed
> -- Performing Test HAVE_VIDEO_OPENGL
> -- Performing Test HAVE_VIDEO_OPENGL - Success |
Before the commit 6a2af48, SDL2 was built for Wayland without OpenGL support on your system. |
Thanks! The thing is, I do have a working EGL via mesa, but do not have GLX. So version 2.0.14, without these flags does detect this:
Notice that 2.0.16, on the other hand does this:
So it sets |
I dug a little bit more and now I see that I do have in my system both |
Both headers were installed by mesa, which was built for platform wayland with egl enabled and glx disabled, with this configuration:
|
Checking for glx.h does not make sense on a pure Wayland system (because it is based on EGL). |
Perfect. Thanks for clarification! |
After commit
6a2af48ad73f8fc4e129ae7fc60589c82923224d
the Wayland build of SDL on a completely X-less system crashes on SDL_CreateWindow with
failed to create an EGL window surface
example program:
(build and run with
g++ $(pkg-config --libs --cflags sdl2) -o simple simple.cpp && ./simple
)On the previous commits, including previous releases, the code works.
And this is how SDL is being built:
The text was updated successfully, but these errors were encountered: