diff options
Diffstat (limited to 'xorg-server/glx/glapi.c')
-rw-r--r-- | xorg-server/glx/glapi.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/xorg-server/glx/glapi.c b/xorg-server/glx/glapi.c index 02e06ac1e..334f33f9f 100644 --- a/xorg-server/glx/glapi.c +++ b/xorg-server/glx/glapi.c @@ -35,15 +35,21 @@ #include <dix-config.h> #include <X11/Xfuncproto.h> #include <os.h> +#ifdef _MSC_VER +#define PUBLIC _declspec(dllexport) +#else #define PUBLIC _X_EXPORT +#endif #include <stdlib.h> #include <string.h> #ifdef DEBUG #include <assert.h> #endif +#include <unistd.h> #include "glapi.h" +#include "glheader.h" #include "dispatch.h" #include "glapitable.h" @@ -125,7 +131,7 @@ _glapi_check_multithread(void) * The context pointer is an opaque type which should be cast to * void from the real context pointer type. */ -PUBLIC void +void _glapi_set_context(void *context) { #if defined(GLX_USE_TLS) @@ -143,7 +149,7 @@ _glapi_set_context(void *context) * The context pointer is an opaque type which should be cast from * void to the real context pointer type. */ -PUBLIC void * +void * _glapi_get_context(void) { #if defined(GLX_USE_TLS) @@ -156,7 +162,7 @@ _glapi_get_context(void) /** * Set the global or per-thread dispatch table pointer. */ -PUBLIC void +void _glapi_set_dispatch(struct _glapi_table *dispatch) { #if defined(PTHREADS) || defined(GLX_USE_TLS) @@ -178,7 +184,7 @@ _glapi_set_dispatch(struct _glapi_table *dispatch) /** * Return pointer to current dispatch table for calling thread. */ -PUBLIC struct _glapi_table * +struct _glapi_table * _glapi_get_dispatch(void) { struct _glapi_table *api; @@ -460,7 +466,7 @@ _glapi_add_dispatch(const char *const *function_names, * glXGetProcAddress doesn't exist in the protocol, the drivers never call * this themselves, and neither does the server. warn if it happens though. */ -PUBLIC _glapi_proc +_GLAPI_EXPORT _glapi_proc _glapi_get_proc_address(const char *funcName) { ErrorF("_glapi_get_proc_address called!\n"); @@ -471,7 +477,7 @@ _glapi_get_proc_address(const char *funcName) * Return size of dispatch table struct as number of functions (or * slots). */ -PUBLIC GLuint +GLuint _glapi_get_dispatch_table_size(void) { return DISPATCH_TABLE_SIZE; |