sis: ifdef out unused variable.
[mesa.git] / src / mesa / glapi / gl_table.py
index 52b4be1d2b55f291590f10c605a3e8269c3dbd33..0e05b3431a17b76cb4d5061d668d821ceef95966 100644 (file)
@@ -49,10 +49,13 @@ class PrintGlTable(gl_XML.gl_print_base):
 
        def printRealHeader(self):
                print '#ifndef GLAPIENTRYP'
-               print '#define GLAPIENTRYP'
+               print '# ifndef GLAPIENTRY'
+               print '#  define GLAPIENTRY'
+               print '# endif'
+               print ''
+               print '# define GLAPIENTRYP GLAPIENTRY *'
                print '#endif'
                print ''
-               print 'typedef void (*_glapi_proc)(void); /* generic function pointer */'
                print ''
                print 'struct _glapi_table'
                print '{'
@@ -68,15 +71,18 @@ class PrintRemapTable(gl_XML.gl_print_base):
        def __init__(self):
                gl_XML.gl_print_base.__init__(self)
 
-               self.header_tag = '_DISPATCH_H_'
+               self.header_tag = '_GLAPI_DISPATCH_H_'
                self.name = "gl_table.py (from Mesa)"
                self.license = license.bsd_license_template % ("(C) Copyright IBM Corporation 2005", "IBM")
                return
 
 
        def printRealHeader(self):
-               print """/**
- * \\file dispatch.h
+               print """
+/* this file should not be included directly in mesa */
+
+/**
+ * \\file glapidispatch.h
  * Macros for handling GL dispatch tables.
  *
  * For each known GL function, there are 3 macros in this file.  The first
@@ -128,7 +134,7 @@ class PrintRemapTable(gl_XML.gl_print_base):
 
 
                print ''
-               print '#if !defined(IN_DRI_DRIVER)'
+               print '#if !defined(_GLAPI_USE_REMAP_TABLE)'
                print ''
 
                for [f, index] in functions:
@@ -158,7 +164,7 @@ class PrintRemapTable(gl_XML.gl_print_base):
 
 
                print ''
-               print '#endif /* !defined(IN_DRI_DRIVER) */'
+               print '#endif /* !defined(_GLAPI_USE_REMAP_TABLE) */'
                return