Module: Mesa
Branch: master
Commit: 569bd281c1f5c3b64f4caab2c76611dfa2e6948c
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=569bd281c1f5c3b64f4caab2c76611dfa2e6948c

Author: Matt Turner <[email protected]>
Date:   Tue Mar 12 12:36:06 2013 -0700

gles1: Add an ABI-check test

Checks that no functions are exported that are not part of the ABI.

Note that currently we are exporting functions that are aliased to
functions that are part of the ABI. They shouldn't be exported, but the
XML descriptions don't adequately describe this case.

---

 src/mapi/es1api/ABI-check   |  254 +++++++++++++++++++++++++++++++++++++++++++
 src/mapi/es1api/Makefile.am |    2 +
 2 files changed, 256 insertions(+), 0 deletions(-)

diff --git a/src/mapi/es1api/ABI-check b/src/mapi/es1api/ABI-check
new file mode 100755
index 0000000..0e31f43
--- /dev/null
+++ b/src/mapi/es1api/ABI-check
@@ -0,0 +1,254 @@
+#!/bin/bash
+
+# Print defined gl.* functions not in GL ES 1.1 or in
+# (FIXME, none of these should be part of the ABI)
+# GL_EXT_discard_framebuffer
+# GL_OES_fixed_point
+# GL_OES_single_precision
+
+# or in extensions that are part of the ES 1.1 extension pack.
+# (see 
http://www.khronos.org/registry/gles/specs/1.1/opengles_spec_1_1_extension_pack.pdf)
+
+FUNCS=$(nm -D --defined-only ${1-.libs/libGLESv1_CM.so.1} | grep -o 'T gl.*' | 
cut -c 3- | while read func; do
+( grep -q "^$func$" || echo $func )  <<EOF
+glActiveTexture
+glAlphaFunc
+glAlphaFuncx
+glAlphaFuncxOES
+glBindBuffer
+glBindFramebufferOES
+glBindRenderbufferOES
+glBindTexture
+glBlendEquationOES
+glBlendEquationSeparateOES
+glBlendFunc
+glBlendFuncSeparateOES
+glBufferData
+glBufferSubData
+glCheckFramebufferStatusOES
+glClear
+glClearColor
+glClearColorx
+glClearColorxOES
+glClearDepthf
+glClearDepthfOES
+glClearDepthx
+glClearDepthxOES
+glClearStencil
+glClientActiveTexture
+glClipPlanef
+glClipPlanefOES
+glClipPlanex
+glClipPlanexOES
+glColor4f
+glColor4ub
+glColor4x
+glColor4xOES
+glColorMask
+glColorPointer
+glCompressedTexImage2D
+glCompressedTexSubImage2D
+glCopyTexImage2D
+glCopyTexSubImage2D
+glCullFace
+glDeleteBuffers
+glDeleteFramebuffersOES
+glDeleteRenderbuffersOES
+glDeleteTextures
+glDepthFunc
+glDepthMask
+glDepthRangef
+glDepthRangefOES
+glDepthRangex
+glDepthRangexOES
+glDisable
+glDisableClientState
+glDiscardFramebufferEXT
+glDrawArrays
+glDrawElements
+glDrawTexfOES
+glDrawTexfvOES
+glDrawTexiOES
+glDrawTexivOES
+glDrawTexsOES
+glDrawTexsvOES
+glDrawTexxOES
+glDrawTexxvOES
+glEGLImageTargetRenderbufferStorageOES
+glEGLImageTargetTexture2DOES
+glEnable
+glEnableClientState
+glFinish
+glFlush
+glFlushMappedBufferRangeEXT
+glFogf
+glFogfv
+glFogx
+glFogxOES
+glFogxv
+glFogxvOES
+glFramebufferRenderbufferOES
+glFramebufferTexture2DOES
+glFrontFace
+glFrustumf
+glFrustumfOES
+glFrustumx
+glFrustumxOES
+glGenBuffers
+glGenerateMipmapOES
+glGenFramebuffersOES
+glGenRenderbuffersOES
+glGenTextures
+glGetBooleanv
+glGetBufferParameteriv
+glGetBufferPointervOES
+glGetClipPlanef
+glGetClipPlanefOES
+glGetClipPlanex
+glGetClipPlanexOES
+glGetError
+glGetFixedv
+glGetFixedvOES
+glGetFloatv
+glGetFramebufferAttachmentParameterivOES
+glGetIntegerv
+glGetLightfv
+glGetLightxv
+glGetLightxvOES
+glGetMaterialfv
+glGetMaterialxv
+glGetMaterialxvOES
+glGetPointerv
+glGetRenderbufferParameterivOES
+glGetString
+glGetTexEnvfv
+glGetTexEnviv
+glGetTexEnvxv
+glGetTexEnvxvOES
+glGetTexGenfvOES
+glGetTexGenivOES
+glGetTexGenxvOES
+glGetTexParameterfv
+glGetTexParameteriv
+glGetTexParameterxv
+glGetTexParameterxvOES
+glHint
+glIsBuffer
+glIsEnabled
+glIsFramebufferOES
+glIsRenderbufferOES
+glIsTexture
+glLightf
+glLightfv
+glLightModelf
+glLightModelfv
+glLightModelx
+glLightModelxOES
+glLightModelxv
+glLightModelxvOES
+glLightx
+glLightxOES
+glLightxv
+glLightxvOES
+glLineWidth
+glLineWidthx
+glLineWidthxOES
+glLoadIdentity
+glLoadMatrixf
+glLoadMatrixx
+glLoadMatrixxOES
+glLogicOp
+glMapBufferOES
+glMapBufferRangeEXT
+glMaterialf
+glMaterialfv
+glMaterialx
+glMaterialxOES
+glMaterialxv
+glMaterialxvOES
+glMatrixMode
+glMultiDrawArraysEXT
+glMultiDrawElementsEXT
+glMultiTexCoord4f
+glMultiTexCoord4x
+glMultiTexCoord4xOES
+glMultMatrixf
+glMultMatrixx
+glMultMatrixxOES
+glNormal3f
+glNormal3x
+glNormal3xOES
+glNormalPointer
+glOrthof
+glOrthofOES
+glOrthox
+glOrthoxOES
+glPixelStorei
+glPointParameterf
+glPointParameterfv
+glPointParameterx
+glPointParameterxOES
+glPointParameterxv
+glPointParameterxvOES
+glPointSize
+glPointSizePointerOES
+glPointSizex
+glPointSizexOES
+glPolygonOffset
+glPolygonOffsetx
+glPolygonOffsetxOES
+glPopMatrix
+glPushMatrix
+glQueryMatrixxOES
+glReadPixels
+glRenderbufferStorageOES
+glRotatef
+glRotatex
+glRotatexOES
+glSampleCoverage
+glSampleCoveragex
+glSampleCoveragexOES
+glScalef
+glScalex
+glScalexOES
+glScissor
+glShadeModel
+glStencilFunc
+glStencilMask
+glStencilOp
+glTexCoordPointer
+glTexEnvf
+glTexEnvfv
+glTexEnvi
+glTexEnviv
+glTexEnvx
+glTexEnvxOES
+glTexEnvxv
+glTexEnvxvOES
+glTexGenfOES
+glTexGenfvOES
+glTexGeniOES
+glTexGenivOES
+glTexGenxOES
+glTexGenxvOES
+glTexImage2D
+glTexParameterf
+glTexParameterfv
+glTexParameteri
+glTexParameteriv
+glTexParameterx
+glTexParameterxOES
+glTexParameterxv
+glTexParameterxvOES
+glTexSubImage2D
+glTranslatef
+glTranslatex
+glTranslatexOES
+glUnmapBufferOES
+glVertexPointer
+glViewport
+EOF
+done)
+
+test ! -n "$FUNCS" || echo $FUNCS
+test ! -n "$FUNCS"
diff --git a/src/mapi/es1api/Makefile.am b/src/mapi/es1api/Makefile.am
index c163a39..bd3c60d 100644
--- a/src/mapi/es1api/Makefile.am
+++ b/src/mapi/es1api/Makefile.am
@@ -28,6 +28,8 @@ AM_CPPFLAGS = \
 
 AM_CFLAGS = $(VISIBILITY_CFLAGS)
 
+TESTS = ABI-check
+
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = glesv1_cm.pc
 

_______________________________________________
mesa-commit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to