egl: Don't advertise unsupported platform extensions
authorChad Versace <chadversary@chromium.org>
Wed, 12 Oct 2016 22:52:12 +0000 (15:52 -0700)
committerChad Versace <chadversary@chromium.org>
Fri, 14 Oct 2016 18:19:27 +0000 (11:19 -0700)
commitc177ef9d47943f648a13beed14269f468583c16e
tree8980956045b42c241c710dc956389b76bc1aa0c1
parent27f4e381736f0abee35aa25035cb54b5c34f9bef
egl: Don't advertise unsupported platform extensions

Mesa's set of supported platform extensions depends on the autoconf
option --with-egl-platforms=foo,bar,baz. If --with-egl-platforms lacks
foo, then eglGetPlatformDisplay(EGL_PLATFORM_FOO, ...) unconditonally
fails.

So, if --with-egl-platforms lacks foo, then remove
EGL_VENDOR_platform_foo from the EGL client extension string.

Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
src/egl/main/eglglobals.c