From eb76efecabd1832759897f1555a68bc2091110f1 Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Sep 23 2016 07:53:55 +0000 Subject: Fix detection of EGL client extensions --- diff --git a/0001-egl-Be-somewhat-aware-of-EGL-client-extensions.patch b/0001-egl-Be-somewhat-aware-of-EGL-client-extensions.patch new file mode 100644 index 0000000..c3a879b --- /dev/null +++ b/0001-egl-Be-somewhat-aware-of-EGL-client-extensions.patch @@ -0,0 +1,39 @@ +From 79b1a811651f41a0647d70d19c7b37c0d728ccfa Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Fri, 23 Sep 2016 03:22:21 -0400 +Subject: [PATCH] egl: Be somewhat aware of EGL client extensions + +Client extensions are only listed in eglQueryString(dpy=NULL). Without +this we can't call anything from e.g. EXT_platform_base. + +Signed-off-by: Adam Jackson +--- + src/dispatch_egl.c | 9 ++------- + 1 file changed, 2 insertions(+), 7 deletions(-) + +diff --git a/src/dispatch_egl.c b/src/dispatch_egl.c +index 9649ba4..b42aacd 100644 +--- a/src/dispatch_egl.c ++++ b/src/dispatch_egl.c +@@ -54,16 +54,11 @@ epoxy_egl_version(EGLDisplay dpy) + bool + epoxy_conservative_has_egl_extension(const char *ext) + { +- EGLDisplay dpy = eglGetCurrentDisplay(); +- +- if (!dpy) +- return true; +- +- return epoxy_has_egl_extension(dpy, ext); ++ return epoxy_has_egl_extension(eglGetCurrentDisplay(), ext); + } + + PUBLIC bool + epoxy_has_egl_extension(EGLDisplay dpy, const char *ext) + { +- return epoxy_extension_in_string(eglQueryString(dpy, EGL_EXTENSIONS), ext); ++ return epoxy_extension_in_string(eglQueryString(dpy, EGL_EXTENSIONS), ext) || epoxy_extension_in_string(eglQueryString(NULL, EGL_EXTENSIONS), ext); + } +-- +2.9.3 +