On Mon 11 May 2015, Emil Velikov wrote:
> The EGL 1.3, 1.4 and 1.5 spec explicitly mentions that providing
> static symbols for functions provided by EGL extensions is not portable.
> Considering that relatively recently we've seen a non-mesa desktop EGL
> implementation, the fact that we opt for such behaviour has gone
> unnoticed.

This patch is sufficiently contentious that it warrants a specification
quote. Please drop it into the commit message.

    From the EGL 1.5 specification:
        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.

> To encourage devs against writing such non-portable code, let's hide the
> symbols similar to the official binary driver from NVIDIA.

I think this patch is a good idea, and I consider it Mesa's mistake that
it has statically exposed these extension functions for so long. But,
I'm also afraid of that this patch may break existing apps that were
linked against Mesa in a non-portable way.

I've convinced myself that this patch is the right thing to do, even if
it does break some non-portable apps.

    1. Any apps that get broken as a consequence of this patch were
       written in a non-portable way, and therefore will break anyway
       when ran against ARM's or Nvidia's EGL library.
    2. "Non-portable" means, in my opinion, not only non-portable across
       different vendor's implementations of libEGL but also across
       versions of a single vendor's implementation. So, this patch does
       not violate any ABI contract provided Mesa's libEGL.

So, I give it
Reviewed-by: Chad Versace <chad.vers...@intel.com>

> Gents,
>
> Considering your experience with mesa and other vendors' EGL
> implementations would you envision any conflicts that this may cause ?


> Cc: Brian Paul <bri...@vmware.com>
> Cc: Chad Versace <chad.vers...@intel.com>
> Cc: Daniel Kurtz <djku...@chromium.org>
> Signed-off-by: Emil Velikov <emil.l.veli...@gmail.com>
> ---
>  src/egl/main/eglapi.c      | 265 
> ++++++++++++++++++++++-----------------------
>  src/egl/main/egltypedefs.h |   2 -
>  2 files changed, 132 insertions(+), 135 deletions(-)
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to