Skip to content

Compile Error modules/video_output/xcb/glx.c with NVidia glxext.h Headers

With NVidia Driver Package - 285.05.33 Source /usr/include/GL/glxext.h

#ifndef GLX_EXT_swap_control
#define GLX_EXT_swap_control 1
#ifdef GLX_GLXEXT_PROTOTYPES
extern void glXSwapIntervalEXT(Display *dpy,
                               GLXDrawable drawable,
                               int interval);
#endif
typedef void ( * PFNGLXSWAPINTERVALEXTPROC) (Display *dpy,
                                             GLXDrawable drawable,
                                             int interval);
#endif

my workaround...

/**
* @file   vlc-2.0.1-xcb-glXSwapIntervalEXT.diff
* @short  diff options:-Nau6
*/
--- ./modules/video_output/xcb/glx.c.orig	2012-05-03 10:02:05.915876066 +0200
+++ ./modules/video_output/xcb/glx.c	2012-05-03 10:08:50.650552547 +0200
@@ -378,13 +378,16 @@
     }
 #endif
 #ifdef GLX_EXT_swap_control
     if (HasExtension (glx_extensions, "GLX_EXT_swap_control")) {
         PFNGLXSWAPINTERVALEXTPROC SwapIntervalEXT = (PFNGLXSWAPINTERVALEXTPROC)GetProcAddress (NULL, "glXSwapIntervalEXT");
         if (!is_swap_interval_set && SwapIntervalEXT)
-            is_swap_interval_set = !SwapIntervalEXT (dpy, sys->glwin, 1);
+        {
+          SwapIntervalEXT (dpy, sys->glwin, 1);
+          is_swap_interval_set = true;
+        }
     }
 #endif
 
     /* Initialize common OpenGL video display */
     sys->gl.lock = NULL;
     sys->gl.unlock = NULL;

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information