i915: Fix driver for the miptree x/y offset changes.
[mesa.git] / src / mesa / drivers / x11 / glxapi.c
index 309a0008d768cb1ca540ad3b512ea7df0ea77078..02eea25a7129a90aa616ddeae938b31af46db0fb 100644 (file)
@@ -34,8 +34,9 @@
 #include <stdlib.h>
 #include <stdio.h>
 #include <string.h>
-#include "glheader.h"
-#include "glapi.h"
+#include "main/glheader.h"
+#include "main/compiler.h"
+#include "glapi/glapi.h"
 #include "glxapi.h"
 
 
@@ -1374,7 +1375,12 @@ _glxapi_get_proc_address(const char *funcName)
 {
    GLuint i;
    for (i = 0; GLX_functions[i].Name; i++) {
+#ifdef MANGLE
+      /* skip the "m" prefix on the name */
+      if (strcmp(GLX_functions[i].Name, funcName+1) == 0)
+#else
       if (strcmp(GLX_functions[i].Name, funcName) == 0)
+#endif
          return GLX_functions[i].Address;
    }
    return NULL;