]> git.mxchange.org Git - flightgear.git/commitdiff
Tweaks to help building with MSVC++
authorcurt <curt>
Tue, 6 Jan 1998 01:20:16 +0000 (01:20 +0000)
committercurt <curt>
Tue, 6 Jan 1998 01:20:16 +0000 (01:20 +0000)
LaRCsim/ls_interface.c
LaRCsim/ls_sim_control.h
Scenery/common.c
Scenery/geometry.c
Scenery/moon.c
Time/event.c

index a1200045de42e451df4ad6f9bb6c4dd6ad8ad124..32bbe8112e435bfc776fba05e6602013087b326c 100644 (file)
@@ -291,8 +291,9 @@ void ls_stamp()
     sprintf(sim_control_.date_string, "%06d\0", date);
     sprintf(sim_control_.time_stamp, "%02d:%02d:%02d\0", 
        nowtime->tm_hour, nowtime->tm_min, nowtime->tm_sec);
+#ifdef COMPILE_THIS_CODE_THIS_USELESS_CODE
     cuserid( sim_control_.userid );    /* set up user id */
-
+#endif /* COMPILE_THIS_CODE_THIS_USELESS_CODE */
     return;
 }
 
@@ -912,6 +913,9 @@ int fgLaRCsim_2_Flight (struct fgFLIGHT *f) {
 /* Flight Gear Modification Log
  *
  * $Log$
+ * Revision 1.12  1998/01/06 01:20:16  curt
+ * Tweaks to help building with MSVC++
+ *
  * Revision 1.11  1998/01/05 22:19:26  curt
  * #ifdef'd out some unused code that was problematic for MSVC++ to compile.
  *
index fbbe2a03d455540449f66962dcd10ee9b6dde1b1..c37f559f50557c18c6ff0236cb6e24a062d5cfa8 100644 (file)
@@ -40,6 +40,9 @@
 
 $Header$
 $Log$
+Revision 1.2  1998/01/06 01:20:17  curt
+Tweaks to help building with MSVC++
+
 Revision 1.1  1997/05/29 00:09:59  curt
 Initial Flight Gear revision.
 
@@ -75,7 +78,9 @@ typedef struct {
   int run_number;      /* run number of this session                     */
   char date_string[7];         /* like "931220" */
   char time_stamp[9];          /* like "13:00:00" */
+#ifdef COMPILE_THIS_CODE_THIS_USELESS_CODE
   char userid[L_cuserid]; /* who is running this sim */
+#endif /* COMPILE_THIS_CODE_THIS_USELESS_CODE */
   long time_slices;    /* number of points that can be recorded (circ buff) */
   int write_av;                /* will be writing out an Agile_VU file after run */
   int write_mat;       /* will be writing out a matrix script of session */
index 6c522c6081d199a13f50f7be4665c2967769ea3c..370144b6ab9eace5ca46eee8743ff8ae1ad2128d 100644 (file)
  **************************************************************************/
 
 
+#ifdef WIN32
+#include <string.h>
+#endif
+
 #include "common.h"
 
 
@@ -44,9 +48,12 @@ char *strip_quotes(char *s) {
 
 
 /* $Log$
-/* Revision 1.2  1997/05/23 15:40:41  curt
-/* Added GNU copyright headers.
+/* Revision 1.3  1998/01/06 01:20:23  curt
+/* Tweaks to help building with MSVC++
 /*
+ * Revision 1.2  1997/05/23 15:40:41  curt
+ * Added GNU copyright headers.
+ *
  * Revision 1.1  1997/05/16 16:07:03  curt
  * Initial revision.
  *
index da2b4b7bb9ce8f985bab7df3b207e2c2bdb52e15..1d09709210f89c8ab587babe1930900dd362b4b6 100644 (file)
@@ -113,15 +113,19 @@ int vrmlFreeGeometry() {
          * because we need it to calculate current ground elevation
          * ... */
        /* free(eg.mesh_data); */
+       ;
     }
     return(vrmlGeometryType);
 }
 
 
 /* $Log$
-/* Revision 1.4  1997/08/27 03:30:26  curt
-/* Changed naming scheme of basic shared structures.
+/* Revision 1.5  1998/01/06 01:20:23  curt
+/* Tweaks to help building with MSVC++
 /*
+ * Revision 1.4  1997/08/27 03:30:26  curt
+ * Changed naming scheme of basic shared structures.
+ *
  * Revision 1.3  1997/07/08 18:20:13  curt
  * Working on establishing a hard ground.
  *
index 4f4652be41532b9a69b42dd7e1e6812e59e23c30..dd39f072229f77cd1bbfaaa6fb953ece6dd37a6d 100644 (file)
@@ -29,6 +29,7 @@
 #include "moon.h"
 
 #include "../Aircraft/aircraft.h"
+#include "../Include/constants.h"
 #include "../Include/general.h"
 #include "../Main/views.h"
 #include "../Time/fg_time.h"
@@ -242,7 +243,7 @@ struct CelestialCoord fgCalculateMoon(struct OrbElements params,
   rho = 0.99883 + 0.00167 * cos(2 * fgDegToRad(FG_Latitude));
 
   if (geocCoord.RightAscension < 0)
-    geocCoord.RightAscension += (2*M_PI);
+    geocCoord.RightAscension += (2*FG_PI);
 
   HA = t.lst - (3.8197186 * geocCoord.RightAscension);
 
@@ -319,9 +320,12 @@ void fgMoonRender() {
 
 
 /* $Log$
-/* Revision 1.15  1998/01/05 18:44:35  curt
-/* Add an option to advance/decrease time from keyboard.
+/* Revision 1.16  1998/01/06 01:20:24  curt
+/* Tweaks to help building with MSVC++
 /*
+ * Revision 1.15  1998/01/05 18:44:35  curt
+ * Add an option to advance/decrease time from keyboard.
+ *
  * Revision 1.14  1997/12/30 20:47:50  curt
  * Integrated new event manager with subsystem initializations.
  *
index 8376c4441fc13b017c7a21d0f75b01759e60fd2e..6eb8c0c4521df112f62e36df7c7cba7530688461 100644 (file)
@@ -28,6 +28,7 @@
 #include <stdio.h>
 
 #ifdef USE_FTIME
+#  include <stdlib.h>
 #  include <sys/timeb.h> /* for ftime() and struct timeb */
 #else
 #  include <sys/time.h>  /* for get/setitimer, gettimeofday, struct timeval */
@@ -268,7 +269,7 @@ void fgEventPrintStats() {
        printf("-----------\n");
 
        for ( i = 0; i < event_ptr; i++ ) {
-           printf("  %-20s  int=%.2fs cum=%d min=%d max=%d count=%d ave=%.2f\n",
+           printf("  %-20s  int=%.2fs cum=%ld min=%ld max=%ld count=%ld ave=%.2f\n",
                   events[i].description, 
                   events[i].interval / 1000.0,
                   events[i].cum_time, 
@@ -335,9 +336,12 @@ void fgEventProcess() {
 
 
 /* $Log$
-/* Revision 1.4  1997/12/31 17:46:50  curt
-/* Tweaked fg_time.c to be able to use ftime() instead of gettimeofday()
+/* Revision 1.5  1998/01/06 01:20:27  curt
+/* Tweaks to help building with MSVC++
 /*
+ * Revision 1.4  1997/12/31 17:46:50  curt
+ * Tweaked fg_time.c to be able to use ftime() instead of gettimeofday()
+ *
  * Revision 1.3  1997/12/30 22:22:42  curt
  * Further integration of event manager.
  *