gnu: Restore allegro-mesa-18.2.5-and-later.patch.

Dropped in 49405aaf5c, it's still in use
by the (leaf) allegro-5.0 package.

* gnu/packages/patches/allegro-mesa-18.2.5-and-later.patch: Newish file.
* gnu/local.mk (dist_patch_DATA): Re-add it.
This commit is contained in:
Tobias Geerinckx-Rice 2019-06-10 01:25:17 +02:00
parent 310c89e330
commit c447eb4d1d
No known key found for this signature in database
GPG key ID: 0DB0FF884F556D79
2 changed files with 42 additions and 0 deletions

View file

@ -662,6 +662,7 @@ dist_patch_DATA = \
%D%/packages/patches/aegisub-icu59-include-unistr.patch \
%D%/packages/patches/aegisub-boost68.patch \
%D%/packages/patches/agg-am_c_prototype.patch \
%D%/packages/patches/allegro-mesa-18.2.5-and-later.patch \
%D%/packages/patches/amule-crypto-6.patch \
%D%/packages/patches/antiword-CVE-2014-8123.patch \
%D%/packages/patches/antlr3-3_1-fix-java8-compilation.patch \

View file

@ -0,0 +1,41 @@
Fixes compilation with Mesa >= 18.2.5.
Taken from upstream:
https://github.com/liballeg/allegro5/commit/a40d30e21802ecf5c9382cf34af9b01bd3781e47
diff --git a/include/allegro5/allegro_opengl.h b/include/allegro5/allegro_opengl.h
index 0f86a6768..652dd024e 100644
--- a/include/allegro5/allegro_opengl.h
+++ b/include/allegro5/allegro_opengl.h
@@ -103,10 +103,14 @@
/* HACK: Prevent both Mesa and SGI's broken headers from screwing us */
#define __glext_h_
+#define __gl_glext_h_
#define __glxext_h_
+#define __glx_glxext_h_
#include <GL/gl.h>
#undef __glext_h_
+#undef __gl_glext_h_
#undef __glxext_h_
+#undef __glx_glxext_h_
#endif /* ALLEGRO_MACOSX */
diff --git a/include/allegro5/opengl/GLext/glx_ext_defs.h b/include/allegro5/opengl/GLext/glx_ext_defs.h
index 49c502091..fba8aea5d 100644
--- a/include/allegro5/opengl/GLext/glx_ext_defs.h
+++ b/include/allegro5/opengl/GLext/glx_ext_defs.h
@@ -1,7 +1,9 @@
/* HACK: Prevent both Mesa and SGI's broken headers from screwing us */
#define __glxext_h_
+#define __glx_glxext_h_
#include <GL/glx.h>
#undef __glxext_h_
+#undef __glx_glxext_h_
#ifndef GLX_VERSION_1_3
#define _ALLEGRO_GLX_VERSION_1_3
--
2.20.0