[waffle] [PATCH 5/7] egl: Optionally dlsym eglGetPlatformDisplay

Chad Versace chadversary at chromium.org
Wed Oct 19 21:46:11 UTC 2016


On Tue 18 Oct 2016, Emil Velikov wrote:
> On 18 October 2016 at 17:58, Chad Versace <chadversary at chromium.org> wrote:
> > +#define RETRIEVE_EGL_SYMBOL_OPTIONAL(function)                         \
> > +    self->function = dlsym(self->eglHandle, #function);
> > +
> Not 100% sure if dlsym should be used here. Need to double-check if
> exposing the EGL 1.5 isn't "against the rules".

Yep. The patch needs fixing.

The spec says eglGetProcAddress must work on core EGL functions. dlsym
may work if the vendor chooses to support it.

>From the EGL 1.5 spec:

    eglGetProcAddress may be queried for all EGL and client API
    functions supported by the implementation (whether those functions
    are extensions or not, and whether they are supported by the current
    client API context or not).

    For functions that are queryable with eglGetProcAddress,
    implementations may choose to also export those functions statically
    from the object libraries implementing those functions. However,
    portable clients cannot rely on this behavior.



More information about the waffle mailing list