[Mesa-dev] [PATCH] egl/main: fix EGL_KHR_get_all_proc_addresses

Emil Velikov emil.l.velikov at gmail.com
Mon May 11 16:30:16 PDT 2015


The extension requires that the address of the core functions should be
available via eglGetProcAddress. Currently the list is guarded by
_EGL_GET_CORE_ADDRESSES, which was only set for the scons (windows)
build.

Unconditionally enable it for all the builds (automake, android and
haiku) considering that the extension is not platform specific and is
always enabled.

Chad,
I'm struggling to see if this was working at some point. I'm suspecting
that it was broken since the beginning - commit 7e8ba77c49b (egl: Expose
EGL_KHR_get_all_proc_addresses and its client extension) although I may
be missing something.

If the patch is correct should we just drop the guarding macro rather
than adding the defines into the build ?

Thanks

Cc: Chad Versace <chad.versace at intel.com>
Cc: mesa-stable at lists.freedesktop.org
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
 src/egl/main/Android.mk  | 1 +
 src/egl/main/Makefile.am | 1 +
 src/egl/main/SConscript  | 1 +
 3 files changed, 3 insertions(+)

diff --git a/src/egl/main/Android.mk b/src/egl/main/Android.mk
index 12b66d0..2a6f05e 100644
--- a/src/egl/main/Android.mk
+++ b/src/egl/main/Android.mk
@@ -39,6 +39,7 @@ include $(CLEAR_VARS)
 LOCAL_SRC_FILES := $(SOURCES)
 
 LOCAL_CFLAGS := \
+	-D_EGL_GET_CORE_ADDRESSES=1 \
 	-D_EGL_NATIVE_PLATFORM=_EGL_PLATFORM_ANDROID \
 	-D_EGL_DRIVER_SEARCH_DIR=\"/system/lib/egl\" \
 	-D_EGL_OS_UNIX=1
diff --git a/src/egl/main/Makefile.am b/src/egl/main/Makefile.am
index b661736..f976fc0 100644
--- a/src/egl/main/Makefile.am
+++ b/src/egl/main/Makefile.am
@@ -27,6 +27,7 @@ AM_CFLAGS = \
 	$(DEFINES) \
 	$(VISIBILITY_CFLAGS) \
 	$(EGL_CFLAGS) \
+	-D_EGL_GET_CORE_ADDRESSES=1 \
 	-D_EGL_NATIVE_PLATFORM=$(EGL_NATIVE_PLATFORM) \
 	-D_EGL_DRIVER_SEARCH_DIR=\"$(libdir)/egl\" \
 	-D_EGL_OS_UNIX=1
diff --git a/src/egl/main/SConscript b/src/egl/main/SConscript
index c001283..4f15888 100644
--- a/src/egl/main/SConscript
+++ b/src/egl/main/SConscript
@@ -12,6 +12,7 @@ env.Append(CPPDEFINES = [
 
 if env['platform'] == 'haiku':
     env.Append(CPPDEFINES = [
+        '_EGL_GET_CORE_ADDRESSES',
         '_EGL_NATIVE_PLATFORM=_EGL_PLATFORM_HAIKU',
         '_EGL_OS_UNIX',
         '_EGL_BUILT_IN_DRIVER_HAIKU',
-- 
2.3.5



More information about the mesa-dev mailing list