Mesa (master): glx: fix compilation error when function name not found
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Tue Apr 27 06:36:47 UTC 2021
Module: Mesa
Branch: master
Commit: e1f3770a5cb5b13c573dc2ef1f4b29a1fae11d40
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=e1f3770a5cb5b13c573dc2ef1f4b29a1fae11d40
Author: Tapani Pälli <tapani.palli at intel.com>
Date: Mon Apr 26 08:34:27 2021 +0300
glx: fix compilation error when function name not found
Patch workarounds the problem like commit eec904d29c0 did, this fixes
compilation on older distributions that still use old header.
Fixes: 01ba8a8d02b ("glx: Implement GLX_EXT_no_config_context")
Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
Reviewed-by: Adam Jackson <ajax at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10447>
---
src/glx/create_context.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/glx/create_context.c b/src/glx/create_context.c
index 4294fbf1bc6..e3a513f58f6 100644
--- a/src/glx/create_context.c
+++ b/src/glx/create_context.c
@@ -33,6 +33,14 @@
#error This code requires sizeof(uint32_t) == sizeof(int).
#endif
+/* An "Atrribs/Attribs" typo was fixed in glxproto.h in Nov 2014.
+ * This is in case we don't have the updated header.
+ */
+#if !defined(X_GLXCreateContextAttribsARB) && \
+ defined(X_GLXCreateContextAtrribsARB)
+#define X_GLXCreateContextAttribsARB X_GLXCreateContextAtrribsARB
+#endif
+
_X_HIDDEN GLXContext
glXCreateContextAttribsARB(Display *dpy, GLXFBConfig config,
GLXContext share_context, Bool direct,
More information about the mesa-commit
mailing list