[Mesa-dev] [PATCH mesa v2 6/9] eglapi: move entrypoints list out to its own file

Eric Engestrom eric at engestrom.ch
Tue Feb 21 23:56:49 UTC 2017


This will allow us to make sure the list is always sorted in the next
commit.

Signed-off-by: Eric Engestrom <eric at engestrom.ch>
---
v2: use .h extension for the new file, and track it in LIBEGL_C_FILES (Emil)
---
 src/egl/Makefile.sources     |  1 +
 src/egl/main/eglapi.c        | 78 +-------------------------------------------
 src/egl/main/eglentrypoint.h | 77 +++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 79 insertions(+), 77 deletions(-)
 create mode 100644 src/egl/main/eglentrypoint.h

diff --git a/src/egl/Makefile.sources b/src/egl/Makefile.sources
index 48db8518f8..e6fd3f114c 100644
--- a/src/egl/Makefile.sources
+++ b/src/egl/Makefile.sources
@@ -26,6 +26,7 @@ LIBEGL_C_FILES := \
 	main/eglsurface.h \
 	main/eglsync.c \
 	main/eglsync.h \
+	main/eglentrypoint.h \
 	main/egltypedefs.h
 
 dri2_backend_core_FILES := \
diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
index 4597e10821..77ec5426ec 100644
--- a/src/egl/main/eglapi.c
+++ b/src/egl/main/eglapi.c
@@ -2358,83 +2358,7 @@ eglGetProcAddress(const char *procname)
       _EGLProc function;
    } egl_functions[] = {
 #define EGL_ENTRYPOINT(f) { .name = #f, .function = (_EGLProc) f },
-      /* core functions queryable in the presence of
-       * EGL_KHR_get_all_proc_addresses or EGL 1.5
-       */
-      /* alphabetical order */
-      EGL_ENTRYPOINT(eglBindAPI)
-      EGL_ENTRYPOINT(eglBindTexImage)
-      EGL_ENTRYPOINT(eglBindWaylandDisplayWL)
-      EGL_ENTRYPOINT(eglChooseConfig)
-      EGL_ENTRYPOINT(eglClientWaitSync)
-      EGL_ENTRYPOINT(eglClientWaitSyncKHR)
-      EGL_ENTRYPOINT(eglCopyBuffers)
-      EGL_ENTRYPOINT(eglCreateContext)
-      EGL_ENTRYPOINT(eglCreateDRMImageMESA)
-      EGL_ENTRYPOINT(eglCreateImage)
-      EGL_ENTRYPOINT(eglCreateImageKHR)
-      EGL_ENTRYPOINT(eglCreatePbufferFromClientBuffer)
-      EGL_ENTRYPOINT(eglCreatePbufferSurface)
-      EGL_ENTRYPOINT(eglCreatePixmapSurface)
-      EGL_ENTRYPOINT(eglCreatePlatformPixmapSurface)
-      EGL_ENTRYPOINT(eglCreatePlatformPixmapSurfaceEXT)
-      EGL_ENTRYPOINT(eglCreatePlatformWindowSurface)
-      EGL_ENTRYPOINT(eglCreatePlatformWindowSurfaceEXT)
-      EGL_ENTRYPOINT(eglCreateSync)
-      EGL_ENTRYPOINT(eglCreateSync64KHR)
-      EGL_ENTRYPOINT(eglCreateSyncKHR)
-      EGL_ENTRYPOINT(eglCreateWaylandBufferFromImageWL)
-      EGL_ENTRYPOINT(eglCreateWindowSurface)
-      EGL_ENTRYPOINT(eglDebugMessageControlKHR)
-      EGL_ENTRYPOINT(eglDestroyContext)
-      EGL_ENTRYPOINT(eglDestroyImage)
-      EGL_ENTRYPOINT(eglDestroyImageKHR)
-      EGL_ENTRYPOINT(eglDestroySurface)
-      EGL_ENTRYPOINT(eglDestroySync)
-      EGL_ENTRYPOINT(eglDestroySyncKHR)
-      EGL_ENTRYPOINT(eglDupNativeFenceFDANDROID)
-      EGL_ENTRYPOINT(eglExportDMABUFImageMESA)
-      EGL_ENTRYPOINT(eglExportDMABUFImageQueryMESA)
-      EGL_ENTRYPOINT(eglExportDRMImageMESA)
-      EGL_ENTRYPOINT(eglGetConfigAttrib)
-      EGL_ENTRYPOINT(eglGetConfigs)
-      EGL_ENTRYPOINT(eglGetCurrentContext)
-      EGL_ENTRYPOINT(eglGetCurrentDisplay)
-      EGL_ENTRYPOINT(eglGetCurrentSurface)
-      EGL_ENTRYPOINT(eglGetDisplay)
-      EGL_ENTRYPOINT(eglGetError)
-      EGL_ENTRYPOINT(eglGetPlatformDisplay)
-      EGL_ENTRYPOINT(eglGetPlatformDisplayEXT)
-      EGL_ENTRYPOINT(eglGetProcAddress)
-      EGL_ENTRYPOINT(eglGetSyncAttrib)
-      EGL_ENTRYPOINT(eglGetSyncAttribKHR)
-      EGL_ENTRYPOINT(eglGetSyncValuesCHROMIUM)
-      EGL_ENTRYPOINT(eglInitialize)
-      EGL_ENTRYPOINT(eglLabelObjectKHR)
-      EGL_ENTRYPOINT(eglMakeCurrent)
-      EGL_ENTRYPOINT(eglPostSubBufferNV)
-      EGL_ENTRYPOINT(eglQueryAPI)
-      EGL_ENTRYPOINT(eglQueryContext)
-      EGL_ENTRYPOINT(eglQueryDebugKHR)
-      EGL_ENTRYPOINT(eglQueryString)
-      EGL_ENTRYPOINT(eglQuerySurface)
-      EGL_ENTRYPOINT(eglQueryWaylandBufferWL)
-      EGL_ENTRYPOINT(eglReleaseTexImage)
-      EGL_ENTRYPOINT(eglReleaseThread)
-      EGL_ENTRYPOINT(eglSignalSyncKHR)
-      EGL_ENTRYPOINT(eglSurfaceAttrib)
-      EGL_ENTRYPOINT(eglSwapBuffers)
-      EGL_ENTRYPOINT(eglSwapBuffersRegionNOK)
-      EGL_ENTRYPOINT(eglSwapBuffersWithDamageEXT)
-      EGL_ENTRYPOINT(eglSwapBuffersWithDamageKHR)
-      EGL_ENTRYPOINT(eglSwapInterval)
-      EGL_ENTRYPOINT(eglTerminate)
-      EGL_ENTRYPOINT(eglUnbindWaylandDisplayWL)
-      EGL_ENTRYPOINT(eglWaitClient)
-      EGL_ENTRYPOINT(eglWaitGL)
-      EGL_ENTRYPOINT(eglWaitNative)
-      EGL_ENTRYPOINT(eglWaitSync)
-      EGL_ENTRYPOINT(eglWaitSyncKHR)
+#include "eglentrypoint.h"
 #undef EGL_ENTRYPOINT
    };
    EGLint i;
diff --git a/src/egl/main/eglentrypoint.h b/src/egl/main/eglentrypoint.h
new file mode 100644
index 0000000000..e6318b9311
--- /dev/null
+++ b/src/egl/main/eglentrypoint.h
@@ -0,0 +1,77 @@
+/* core functions queryable in the presence of
+ * EGL_KHR_get_all_proc_addresses or EGL 1.5
+ */
+/* alphabetical order */
+EGL_ENTRYPOINT(eglBindAPI)
+EGL_ENTRYPOINT(eglBindTexImage)
+EGL_ENTRYPOINT(eglBindWaylandDisplayWL)
+EGL_ENTRYPOINT(eglChooseConfig)
+EGL_ENTRYPOINT(eglClientWaitSync)
+EGL_ENTRYPOINT(eglClientWaitSyncKHR)
+EGL_ENTRYPOINT(eglCopyBuffers)
+EGL_ENTRYPOINT(eglCreateContext)
+EGL_ENTRYPOINT(eglCreateDRMImageMESA)
+EGL_ENTRYPOINT(eglCreateImage)
+EGL_ENTRYPOINT(eglCreateImageKHR)
+EGL_ENTRYPOINT(eglCreatePbufferFromClientBuffer)
+EGL_ENTRYPOINT(eglCreatePbufferSurface)
+EGL_ENTRYPOINT(eglCreatePixmapSurface)
+EGL_ENTRYPOINT(eglCreatePlatformPixmapSurface)
+EGL_ENTRYPOINT(eglCreatePlatformPixmapSurfaceEXT)
+EGL_ENTRYPOINT(eglCreatePlatformWindowSurface)
+EGL_ENTRYPOINT(eglCreatePlatformWindowSurfaceEXT)
+EGL_ENTRYPOINT(eglCreateSync)
+EGL_ENTRYPOINT(eglCreateSync64KHR)
+EGL_ENTRYPOINT(eglCreateSyncKHR)
+EGL_ENTRYPOINT(eglCreateWaylandBufferFromImageWL)
+EGL_ENTRYPOINT(eglCreateWindowSurface)
+EGL_ENTRYPOINT(eglDebugMessageControlKHR)
+EGL_ENTRYPOINT(eglDestroyContext)
+EGL_ENTRYPOINT(eglDestroyImage)
+EGL_ENTRYPOINT(eglDestroyImageKHR)
+EGL_ENTRYPOINT(eglDestroySurface)
+EGL_ENTRYPOINT(eglDestroySync)
+EGL_ENTRYPOINT(eglDestroySyncKHR)
+EGL_ENTRYPOINT(eglDupNativeFenceFDANDROID)
+EGL_ENTRYPOINT(eglExportDMABUFImageMESA)
+EGL_ENTRYPOINT(eglExportDMABUFImageQueryMESA)
+EGL_ENTRYPOINT(eglExportDRMImageMESA)
+EGL_ENTRYPOINT(eglGetConfigAttrib)
+EGL_ENTRYPOINT(eglGetConfigs)
+EGL_ENTRYPOINT(eglGetCurrentContext)
+EGL_ENTRYPOINT(eglGetCurrentDisplay)
+EGL_ENTRYPOINT(eglGetCurrentSurface)
+EGL_ENTRYPOINT(eglGetDisplay)
+EGL_ENTRYPOINT(eglGetError)
+EGL_ENTRYPOINT(eglGetPlatformDisplay)
+EGL_ENTRYPOINT(eglGetPlatformDisplayEXT)
+EGL_ENTRYPOINT(eglGetProcAddress)
+EGL_ENTRYPOINT(eglGetSyncAttrib)
+EGL_ENTRYPOINT(eglGetSyncAttribKHR)
+EGL_ENTRYPOINT(eglGetSyncValuesCHROMIUM)
+EGL_ENTRYPOINT(eglInitialize)
+EGL_ENTRYPOINT(eglLabelObjectKHR)
+EGL_ENTRYPOINT(eglMakeCurrent)
+EGL_ENTRYPOINT(eglPostSubBufferNV)
+EGL_ENTRYPOINT(eglQueryAPI)
+EGL_ENTRYPOINT(eglQueryContext)
+EGL_ENTRYPOINT(eglQueryDebugKHR)
+EGL_ENTRYPOINT(eglQueryString)
+EGL_ENTRYPOINT(eglQuerySurface)
+EGL_ENTRYPOINT(eglQueryWaylandBufferWL)
+EGL_ENTRYPOINT(eglReleaseTexImage)
+EGL_ENTRYPOINT(eglReleaseThread)
+EGL_ENTRYPOINT(eglSignalSyncKHR)
+EGL_ENTRYPOINT(eglSurfaceAttrib)
+EGL_ENTRYPOINT(eglSwapBuffers)
+EGL_ENTRYPOINT(eglSwapBuffersRegionNOK)
+EGL_ENTRYPOINT(eglSwapBuffersWithDamageEXT)
+EGL_ENTRYPOINT(eglSwapBuffersWithDamageKHR)
+EGL_ENTRYPOINT(eglSwapInterval)
+EGL_ENTRYPOINT(eglTerminate)
+EGL_ENTRYPOINT(eglUnbindWaylandDisplayWL)
+EGL_ENTRYPOINT(eglWaitClient)
+EGL_ENTRYPOINT(eglWaitGL)
+EGL_ENTRYPOINT(eglWaitNative)
+EGL_ENTRYPOINT(eglWaitSync)
+EGL_ENTRYPOINT(eglWaitSyncKHR)
-- 
Cheers,
  Eric



More information about the mesa-dev mailing list