summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2006-03-29 22:32:38 +0000
committerKristian Høgsberg <krh@redhat.com>2006-03-29 22:32:38 +0000
commit3a6d968f37683835bd92b1b853e0ac8cadd0fdef (patch)
tree7b8d5aa056b3cb00819cbb25c61bb46e8a2a4e99
parentcec74532bf62bb0cb29ea89a34fc7ae14b70648c (diff)
Fixes to silence warnings in code generated by glapi scripts.
-rw-r--r--src/mesa/glapi/Makefile4
-rw-r--r--src/mesa/glapi/glX_proto_recv.py4
-rw-r--r--src/mesa/glapi/glX_proto_size.py2
-rw-r--r--src/mesa/glapi/glapi.c4
4 files changed, 12 insertions, 2 deletions
diff --git a/src/mesa/glapi/Makefile b/src/mesa/glapi/Makefile
index 129e51fb1f..1030e5e2c3 100644
--- a/src/mesa/glapi/Makefile
+++ b/src/mesa/glapi/Makefile
@@ -24,7 +24,9 @@ GLX_DIR = $(XORG_BASE)/GL/glx
SERVER_OUTPUTS = $(GLX_DIR)/indirect_dispatch.c \
$(GLX_DIR)/indirect_dispatch_swap.c \
- $(GLX_DIR)/indirect_dispatch.h
+ $(GLX_DIR)/indirect_dispatch.h \
+ $(GLX_DIR)/indirect_size_get.c \
+ $(GLX_DIR)/indirect_size_get.h
COMMON = gl_XML.py license.py gl_API.xml typeexpr.py
COMMON_GLX = $(COMMON) glX_XML.py glX_proto_common.py
diff --git a/src/mesa/glapi/glX_proto_recv.py b/src/mesa/glapi/glX_proto_recv.py
index a0c4ea0541..86bdd0ec93 100644
--- a/src/mesa/glapi/glX_proto_recv.py
+++ b/src/mesa/glapi/glX_proto_recv.py
@@ -237,7 +237,7 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto):
for param in f.parameterIterator():
- if param.is_counter or param.is_image() or param.is_output or len(param.count_parameter_list):
+ if param.is_counter or param.is_image() or param.is_output or param.name in f.count_parameter_list or len(param.count_parameter_list):
location = param.name
else:
location = self.fetch_param(param)
@@ -360,6 +360,8 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto):
else:
swap_func = self.swap_name(sub[0])
print ' %s = (%s) %s( (%s *) (pc + %s), %s ); break;' % (param.name, param.type_string(), swap_func, self.real_types[sub[0]], o, count_name)
+ print ' default:'
+ print ' return;'
print ' }'
else:
swap_func = self.swap_name(type_size)
diff --git a/src/mesa/glapi/glX_proto_size.py b/src/mesa/glapi/glX_proto_size.py
index 81a98423a4..54232781d2 100644
--- a/src/mesa/glapi/glX_proto_size.py
+++ b/src/mesa/glapi/glX_proto_size.py
@@ -316,6 +316,8 @@ class PrintGlxSizeStubs_c(PrintGlxSizeStubs_common):
print '#include <GL/gl.h>'
if self.emit_get:
print '#include "indirect_size_get.h"'
+ print '#include "glxserver.h"'
+ print '#include "indirect_util.h"'
print '#include "indirect_size.h"'
diff --git a/src/mesa/glapi/glapi.c b/src/mesa/glapi/glapi.c
index 6800205530..3f2ec270fe 100644
--- a/src/mesa/glapi/glapi.c
+++ b/src/mesa/glapi/glapi.c
@@ -60,7 +60,9 @@
static GLboolean WarnFlag = GL_FALSE;
static _glapi_warning_func warning_func;
+#if defined(PTHREADS) || defined(GLX_USE_TLS)
static void init_glapi_relocs(void);
+#endif
static _glapi_proc generate_entrypoint(GLuint functionOffset);
static void fill_in_entrypoint_offset(_glapi_proc entrypoint, GLuint offset);
@@ -1013,6 +1015,7 @@ _glapi_check_table(const struct _glapi_table *table)
}
+#if defined(PTHREADS) || defined(GLX_USE_TLS)
/**
* Perform platform-specific GL API entry-point fixups.
*
@@ -1033,3 +1036,4 @@ init_glapi_relocs( void )
}
#endif /* defined( USE_X86_ASM ) && defined( GLX_USE_TLS ) */
}
+#endif