]> git.mxchange.org Git - flightgear.git/blobdiff - src/WeatherCM/FGTurbulenceItem.h
Moved JSBSim.hxx to src/FDM/JSBSim/
[flightgear.git] / src / WeatherCM / FGTurbulenceItem.h
index 2b9fa3c7cbba07292709ab9d90c1f7214468e296..379748d0777b447bead52da2bd2ea2d7100c5423 100644 (file)
@@ -36,6 +36,8 @@ HISTORY
                                suggestion
 19.10.1999 Christian Mayer     change to use PLIB's sg instead of Point[2/3]D
                                and lots of wee code cleaning
+21.12.1999 Christian Mayer     Added a fix for compatibility to gcc 2.8 which
+                               suggested by Oliver Delise
 *****************************************************************************/
 
 /****************************************************************************/
@@ -47,7 +49,18 @@ HISTORY
 /****************************************************************************/
 /* INCLUDES                                                                */
 /****************************************************************************/
-#include "sg.h"
+
+#ifdef HAVE_CONFIG_H
+#  include <config.h>
+#endif
+
+#include <simgear/compiler.h>
+
+#ifdef HAVE_WINDOWS_H
+#  include <windows.h>
+#endif
+
+#include <plib/sg.h>
 
 #include "FGWeatherDefs.h"
 
@@ -57,6 +70,12 @@ HISTORY
 class FGTurbulenceItem;
 FGTurbulenceItem operator-(const FGTurbulenceItem& arg);
 
+#if ( __GNU_C__ == 2 && __GNU_MAJOR__ < 9 )
+#  define const_sgVec3 const sgVec3
+#else
+#  define const_sgVec3 const sgVec3&
+#endif
+
 /****************************************************************************/
 /* CLASS DECLARATION                                                       */
 /****************************************************************************/
@@ -67,7 +86,7 @@ private:
 
 protected:
 public:
-    FGTurbulenceItem(const sgVec3& v)  { sgCopyVec3(value, v);}
+    FGTurbulenceItem(const_sgVec3 v)   { sgCopyVec3(value, v);}
     FGTurbulenceItem()                 { sgZeroVec3(value);   }
 
     void          getValue(sgVec3 ret) const { sgCopyVec3(ret, value); };