From b2f2fa7c0df83b6bc9366983812e4591920bd302 Mon Sep 17 00:00:00 2001
From: theuni <theuni-nospam-@xbmc.org>
Date: Mon, 18 Jul 2011 00:32:07 -0400
Subject: fixed: trac #11722. compile on platforms where GL_BGRA_EXT is not
 defined

---
 xbmc/guilib/TextureGL.cpp | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/xbmc/guilib/TextureGL.cpp b/xbmc/guilib/TextureGL.cpp
index 520af9e60e..8adf914d80 100644
--- a/xbmc/guilib/TextureGL.cpp
+++ b/xbmc/guilib/TextureGL.cpp
@@ -130,8 +130,15 @@ void CGLTexture::LoadToGPU()
   // All incoming textures are BGRA, which GLES does not necessarily support.
   // Some (most?) hardware supports BGRA textures via an extension.
   // If not, we convert to RGBA first to avoid having to swizzle in shaders.
+  // Explicitly define GL_BGRA_EXT here in the case that it's not defined by
+  // system headers, and trust the extension list instead.
+#ifndef GL_BGRA_EXT
+#define GL_BGRA_EXT 0x80E1
+#endif
+
   GLint internalformat;
   GLenum pixelformat;
+
   if (g_Windowing.SupportsBGRA())
   {
     internalformat = pixelformat = GL_BGRA_EXT;
-- 
cgit v1.2.3