mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 13:28:06 +02:00
glapi: #include "util/glheader.h" in glapi_priv.h and glapitable.h directly
So that we do not need define GLAPIENTRY repeatedly, always using the GLAPIENTRY macro comes from GL/gl.h Signed-off-by: Yonggang Luo <luoyonggang@gmail.com> Reviewed-by: Jesse Natalie <jenatali@microsoft.com> Acked-by: Brian Paul brianp@vmware.com Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19472>
This commit is contained in:
parent
bfa3ce44a6
commit
2c89401f75
10 changed files with 3 additions and 29 deletions
|
|
@ -38,7 +38,6 @@
|
|||
|
||||
#include <GL/gl.h>
|
||||
|
||||
#include "util/glheader.h"
|
||||
#include "glapi.h"
|
||||
#include "glapitable.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,6 @@
|
|||
#include "glxclient.h"
|
||||
#include "apple_glx_context.h"
|
||||
#include "apple_xgl_api.h"
|
||||
#include "util/glheader.h"
|
||||
#include "glapitable.h"
|
||||
|
||||
extern struct _glapi_table * __ogl_framework_api;
|
||||
|
|
|
|||
|
|
@ -40,7 +40,6 @@
|
|||
#include "glxclient.h"
|
||||
#include "apple_glx_context.h"
|
||||
#include "apple_xgl_api.h"
|
||||
#include "util/glheader.h"
|
||||
#include "glapitable.h"
|
||||
|
||||
extern struct _glapi_table * __ogl_framework_api;
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@
|
|||
#include "glxclient.h"
|
||||
#include "apple_glx_context.h"
|
||||
#include "apple_xgl_api.h"
|
||||
#include "util/glheader.h"
|
||||
#include "glapitable.h"
|
||||
|
||||
extern struct _glapi_table * __ogl_framework_api;
|
||||
|
|
|
|||
|
|
@ -49,8 +49,6 @@ header = """/* GLXEXT is the define used in the xserver when the GLX extension i
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "util/glheader.h"
|
||||
|
||||
#include "glapi.h"
|
||||
#include "glapitable.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -49,14 +49,7 @@ class PrintGlTable(gl_XML.gl_print_base):
|
|||
f.return_type, f.name, arg_string, f.offset))
|
||||
|
||||
def printRealHeader(self):
|
||||
print('#ifndef GLAPIENTRYP')
|
||||
print('# ifndef GLAPIENTRY')
|
||||
print('# define GLAPIENTRY')
|
||||
print('# endif')
|
||||
print('')
|
||||
print('# define GLAPIENTRYP GLAPIENTRY *')
|
||||
print('#endif')
|
||||
print('')
|
||||
print('#include "util/glheader.h"')
|
||||
print('')
|
||||
print('#ifdef __cplusplus')
|
||||
print('extern "C" {')
|
||||
|
|
|
|||
|
|
@ -74,11 +74,6 @@
|
|||
|
||||
#endif /* logging */
|
||||
|
||||
|
||||
#ifndef GLAPIENTRY
|
||||
#define GLAPIENTRY
|
||||
#endif
|
||||
|
||||
#ifdef GLX_INDIRECT_RENDERING
|
||||
/* those link to libglapi.a should provide the entry points */
|
||||
#define _GLAPI_SKIP_PROTO_ENTRY_POINTS
|
||||
|
|
@ -150,7 +145,7 @@ GL_API void GL_APIENTRY glBlendBarrier (void);
|
|||
GL_API void GL_APIENTRY glPrimitiveBoundingBox (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW);
|
||||
|
||||
/* Enable frame pointer elimination on Windows, otherwise forgetting to add
|
||||
* APIENTRY to _mesa_* entrypoints will not cause crashes on debug builds, as
|
||||
* GLAPIENTRY to _mesa_* entrypoints will not cause crashes on debug builds, as
|
||||
* the initial ESP value is saved in the EBP in the function prologue, then
|
||||
* restored on the epilogue, clobbering any corruption in the ESP pointer due
|
||||
* to mismatch in the callee calling convention.
|
||||
|
|
|
|||
|
|
@ -26,14 +26,8 @@
|
|||
#ifndef _GLAPI_PRIV_H
|
||||
#define _GLAPI_PRIV_H
|
||||
|
||||
|
||||
#define GL_GLEXT_PROTOTYPES
|
||||
#include "GL/gl.h"
|
||||
#include "GL/glext.h"
|
||||
|
||||
typedef int GLclampx;
|
||||
|
||||
#include "glapi/glapi.h"
|
||||
#include "util/glheader.h"
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
*/
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
#include "util/glheader.h"
|
||||
|
||||
#include "glapi/glapi.h"
|
||||
#include "glapitable.h"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
*/
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
#include "util/glheader.h"
|
||||
|
||||
#include "glapi/glapi.h"
|
||||
#include "glapitable.h"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue