From aaec32efb1c0baceff181e6be72a332aec8a063c Mon Sep 17 00:00:00 2001
From: Fons Rademakers <Fons.Rademakers@cern.ch>
Date: Wed, 12 Feb 2003 13:49:06 +0000
Subject: [PATCH] fix for GL macros on Solaris confusing GL methods in
 TVirtualX.h. Also corrected multiple inclusion macros that were not of the
 format ROOT_filename.

git-svn-id: http://root.cern.ch/svn/root/trunk@6111 27541ba8-7e3a-0410-8455-c3a389f83636
---
 gl/inc/TRootGLU.h          | 13 +++++++++----
 gl/inc/TRootGLViewer.h     |  8 ++++----
 gl/inc/TRootGLX.h          | 11 ++++++++++-
 gl/inc/TRootOIViewer.h     |  4 ++--
 gl/inc/TRootWGL.h          | 10 +++++-----
 gl/inc/TWin32GLViewerImp.h |  6 +++---
 6 files changed, 33 insertions(+), 19 deletions(-)

diff --git a/gl/inc/TRootGLU.h b/gl/inc/TRootGLU.h
index 28ca9212e59..b15741e3af1 100644
--- a/gl/inc/TRootGLU.h
+++ b/gl/inc/TRootGLU.h
@@ -1,4 +1,4 @@
-/* @(#)root/gl:$Name$:$Id$ */
+/* @(#)root/gl:$Name:  $:$Id: TRootGLU.h,v 1.1.1.1 2000/05/16 17:00:47 rdm Exp $ */
 
 /*************************************************************************
  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
@@ -8,13 +8,18 @@
  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
  *************************************************************************/
 
-#ifndef GL_RootGLU
-#define GL_RootGLU
+#ifndef ROOT_TRootGLU
+#define ROOT_TRootGLU
 
 #ifdef WIN32
+#ifndef ROOT_Windows4Root
 #include "Windows4Root.h"
 #endif
+#endif
+
+// avoid inclusion of macros that confuse TVirtualX.h on Solaris
+#define SUN_OGL_NO_VERTEX_MACROS
 
 #include <GL/glu.h>
 
-#endif /* GL_RootGLU */
+#endif
diff --git a/gl/inc/TRootGLViewer.h b/gl/inc/TRootGLViewer.h
index dd47138ec71..0aadab111f1 100644
--- a/gl/inc/TRootGLViewer.h
+++ b/gl/inc/TRootGLViewer.h
@@ -1,4 +1,4 @@
-// @(#)root/gl:$Name:  $:$Id: TRootGLViewer.h,v 1.3 2001/04/11 17:28:08 brun Exp $
+// @(#)root/gl:$Name:  $:$Id: TRootGLViewer.h,v 1.4 2001/11/28 16:01:07 rdm Exp $
 // Author: Fons Rademakers   15/01/98
 
 /*************************************************************************
@@ -28,16 +28,16 @@
 #ifndef ROOT_TGLViewerImp
 #include "TGLViewerImp.h"
 #endif
-#ifndef GL_RootGLU
+#ifndef ROOT_TRootGLU
 #include "TRootGLU.h"
 #endif
 
 #ifdef GDK_WIN32
-#ifndef GL_RootWGL
+#ifndef ROOT_TRootWGL
 #include "TRootWGL.h"
 #endif
 #else
-#ifndef GL_RootGLX
+#ifndef ROOT_TRootGLX
 #include "TRootGLX.h"
 #endif
 #endif
diff --git a/gl/inc/TRootGLX.h b/gl/inc/TRootGLX.h
index 80742d849db..4d2fdeba6be 100644
--- a/gl/inc/TRootGLX.h
+++ b/gl/inc/TRootGLX.h
@@ -1,4 +1,4 @@
-/* @(#)root/gl:$Name$:$Id$ */
+/* @(#)root/gl:$Name:  $:$Id: TRootGLX.h,v 1.1.1.1 2000/05/16 17:00:47 rdm Exp $ */
 
 /*************************************************************************
  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
@@ -11,6 +11,15 @@
 #ifndef ROOT_TRootGLX
 #define ROOT_TRootGLX
 
+#ifdef WIN32
+#ifndef ROOT_Windows4Root
+#include "Windows4Root.h"
+#endif
+#endif
+
+// avoid inclusion of macros that confuse TVirtualX.h on Solaris
+#define SUN_OGL_NO_VERTEX_MACROS
+
 #include <GL/glx.h>
 
 #endif
diff --git a/gl/inc/TRootOIViewer.h b/gl/inc/TRootOIViewer.h
index d51baa86c8f..42d56ca97d6 100644
--- a/gl/inc/TRootOIViewer.h
+++ b/gl/inc/TRootOIViewer.h
@@ -1,4 +1,4 @@
-// @(#)root/gl:$Name:$:$Id:$
+// @(#)root/gl:$Name:  $:$Id: TRootOIViewer.h,v 1.1 2001/04/28 16:23:32 rdm Exp $
 // Author: Valery Fine & Fons Rademakers   5/10/2000 and 28/4/2001
 
 /*************************************************************************
@@ -28,7 +28,7 @@
 #ifndef ROOT_TGLViewerImp
 #include "TGLViewerImp.h"
 #endif
-#ifndef GL_RootGLU
+#ifndef ROOT_TRootGLU
 # include "TRootGLU.h"
 #endif
 
diff --git a/gl/inc/TRootWGL.h b/gl/inc/TRootWGL.h
index fec01e371cc..35ffba41245 100644
--- a/gl/inc/TRootWGL.h
+++ b/gl/inc/TRootWGL.h
@@ -1,4 +1,4 @@
-/* @(#)root/gl:$Name:  $:$Id: TRootWGL.h,v 1.1.1.1 2000/05/16 17:00:47 rdm Exp $ */
+/* @(#)root/gl:$Name:  $:$Id: TRootWGL.h,v 1.2 2001/11/28 16:01:07 rdm Exp $ */
 
 /*************************************************************************
  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
@@ -8,8 +8,8 @@
  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
  *************************************************************************/
 
-#ifndef GL_RootWGL
-#define GL_RootWGL
+#ifndef ROOT_TRootWGL
+#define ROOT_TRootWGL
 
 #ifndef ROOT_Windows4Root
 #include "Windows4Root.h"
@@ -19,6 +19,6 @@
 #include "gdk/gdk.h"
 #endif
 
-#include        <wingdi.h>
+#include <wingdi.h>
 
-#endif /* GL_RootWGL */
+#endif
diff --git a/gl/inc/TWin32GLViewerImp.h b/gl/inc/TWin32GLViewerImp.h
index d11f17c4d96..fc42371e1af 100644
--- a/gl/inc/TWin32GLViewerImp.h
+++ b/gl/inc/TWin32GLViewerImp.h
@@ -1,4 +1,4 @@
-// @(#)root/gl:$Name$:$Id$
+// @(#)root/gl:$Name:  $:$Id: TWin32GLViewerImp.h,v 1.1.1.1 2000/05/16 17:00:47 rdm Exp $
 // Author: Valery Fine(fine@vxcern.cern.ch)   29/12/96
 
 /*************************************************************************
@@ -22,11 +22,11 @@
 //                                                                      //
 //////////////////////////////////////////////////////////////////////////
 
-#ifndef GL_RootWGL
+#ifndef ROOT_TRootWGL
 #include "TRootWGL.h"
 #endif
 
-#ifndef GL_RootGLU
+#ifndef ROOT_TRootGLU
 #include "TRootGLU.h"
 #endif
 
-- 
GitLab