1#include "main/glheader.h" 2#include "main/compiler.h" 3#include "glapi/glapi.h" 4 5/* This is just supposed to make sure we get a reference to 6 the driver entry symbol that the compiler doesn't optimize away */ 7 8extern char __driDriverExtensions[]; 9 10/* provide glapi symbols */ 11 12#if defined(GLX_USE_TLS) 13 14PUBLIC __thread struct _glapi_table * _glapi_tls_Dispatch 15 __attribute__((tls_model("initial-exec"))); 16 17PUBLIC __thread void * _glapi_tls_Context 18 __attribute__((tls_model("initial-exec"))); 19 20PUBLIC const struct _glapi_table *_glapi_Dispatch; 21PUBLIC const void *_glapi_Context; 22 23#else 24 25PUBLIC struct _glapi_table *_glapi_Dispatch; 26PUBLIC void *_glapi_Context; 27 28#endif 29 30PUBLIC void 31_glapi_check_multithread(void) 32{} 33 34PUBLIC void 35_glapi_set_context(void *context) 36{} 37 38PUBLIC void * 39_glapi_get_context(void) 40{ 41 return 0; 42} 43 44PUBLIC void 45_glapi_set_dispatch(struct _glapi_table *dispatch) 46{} 47 48PUBLIC struct _glapi_table * 49_glapi_get_dispatch(void) 50{ 51 return 0; 52} 53 54PUBLIC int 55_glapi_add_dispatch( const char * const * function_names, 56 const char * parameter_signature ) 57{ 58 return 0; 59} 60 61PUBLIC GLint 62_glapi_get_proc_offset(const char *funcName) 63{ 64 return 0; 65} 66 67PUBLIC _glapi_proc 68_glapi_get_proc_address(const char *funcName) 69{ 70 return 0; 71} 72 73PUBLIC GLuint 74_glapi_get_dispatch_table_size(void) 75{ 76 return 0; 77} 78 79PUBLIC unsigned long 80_glthread_GetID(void) 81{ 82 return 0; 83} 84 85int main(int argc, char** argv) 86{ 87 void* p = __driDriverExtensions; 88 return (int)(unsigned long)p; 89} 90