[Mesa-dev] [PATCH] include/GL: fix the interop header for a --disable-glx build

Rob Herring robh at kernel.org
Tue May 17 20:29:29 UTC 2016


Including glx.h brings in X11 headers. Avoid the include of glx.h and just
forward declare the necessary symbols.

Signed-off-by: Rob Herring <robh at kernel.org>
---
I haven't seen any progress and this and builds are still broken. Here's 
a fix as Emil suggested.

Rob

 include/GL/mesa_glinterop.h | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/include/GL/mesa_glinterop.h b/include/GL/mesa_glinterop.h
index 814064d..03646dc 100644
--- a/include/GL/mesa_glinterop.h
+++ b/include/GL/mesa_glinterop.h
@@ -50,13 +50,16 @@
 #ifndef MESA_GLINTEROP_H
 #define MESA_GLINTEROP_H
 
-#include <GL/glx.h>
+#include <GL/gl.h>
 #include <EGL/egl.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+typedef struct _XDisplay Display;
+typedef struct __GLXcontextRec *GLXContext;
+
 /** Returned error codes. */
 enum {
    MESA_GLINTEROP_SUCCESS = 0,
-- 
2.7.4



More information about the mesa-dev mailing list