From dbbad3cdf2c81a8e58d07681d92cb159e57e320e Mon Sep 17 00:00:00 2001 From: ehofman Date: Wed, 20 Oct 2004 08:15:55 +0000 Subject: [PATCH] Frederic: compilation without ENABLE_SP_FMDS defined gave me a lot of link errors. It appeared that symbol used by ADA was still in use in the HUD. There is also a typo from Curt in instrument_mgr.cxx where he #include "kr_87.cxx" instead of "kr_87.hxx" --- src/Cockpit/hud.cxx | 5 ++++- src/Cockpit/hud_ladr.cxx | 13 ++++++++++++- src/Instrumentation/instrument_mgr.cxx | 2 +- 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/src/Cockpit/hud.cxx b/src/Cockpit/hud.cxx index 110d982b0..9212f6e5f 100644 --- a/src/Cockpit/hud.cxx +++ b/src/Cockpit/hud.cxx @@ -455,6 +455,7 @@ readLabel(const SGPropertyNode * node) } } +#ifdef ENABLE_SP_FMDS if ( loadfn== "aux1" ) { load_fn = get_aux1; } else if ( loadfn == "aux2" ) { @@ -491,7 +492,9 @@ readLabel(const SGPropertyNode * node) load_fn = get_aux17; } else if ( loadfn == "aux18" ) { load_fn = get_aux18; - } else if ( loadfn == "ax" ) { + } else +#endif + if ( loadfn == "ax" ) { load_fn = get_Ax; } else if ( loadfn == "speed" ) { load_fn = get_speed; diff --git a/src/Cockpit/hud_ladr.cxx b/src/Cockpit/hud_ladr.cxx index edc4043c2..974475f26 100644 --- a/src/Cockpit/hud_ladr.cxx +++ b/src/Cockpit/hud_ladr.cxx @@ -161,13 +161,14 @@ void HudLadder :: draw( void ) alpha = get_aoa(); pla = get_throttleval(); +#ifdef ENABLE_SP_FMDS int lgear,wown,wowm,ilcanclaw,ihook; ilcanclaw = get_iaux2(); lgear = get_iaux3(); wown = get_iaux4(); wowm = get_iaux5(); ihook = get_iaux6(); - +#endif float pitch_value = current_ch1() * SGD_RADIANS_TO_DEGREES; if(hudladder_type=="Climb/Dive Ladder") { @@ -310,6 +311,7 @@ void HudLadder :: draw( void ) glVertex2f(vel_x, vel_y+6); glEnd(); +#ifdef ENABLE_SP_FMDS // OBJECT MOVING RETICLE // TYPE LINE // ATTRIB - ON CONDITION @@ -346,6 +348,7 @@ void HudLadder :: draw( void ) glVertex2f(vel_x+4, vel_y-8); glEnd(); } +#endif }//if velocity_vector //*************************************************************** @@ -353,6 +356,7 @@ void HudLadder :: draw( void ) // TYPE - SQUARE_BRACKET // ATTRIB - ON CONDITION // alpha bracket +#ifdef ENABLE_SP_FMDS if (alpha_bracket) { if (ihook == 1) { glBegin(GL_LINE_STRIP); @@ -369,6 +373,7 @@ void HudLadder :: draw( void ) glEnd(); } } +#endif //printf("xvr=%f,yvr=%f,Vx=%f,Vy=%f,Vz=%f\n",xvvr,yvvr,Vx,Vy,Vz); //printf("Ax=%f,Ay=%f,Az=%f\n",Ax,Ay,Az); //**************************************************************** @@ -417,6 +422,7 @@ void HudLadder :: draw( void ) // OBJECT STATIC RETICLE // TYPE LINE // ATTRIB - ON CONDITION +#ifdef ENABLE_SP_FMDS if (energy_worm) { if (ilcanclaw == 1) { glBegin(GL_LINE_STRIP); @@ -443,6 +449,7 @@ void HudLadder :: draw( void ) glEnd(); } } +#endif //************************************************************* // OBJECT MOVING RETICLE // TYPE DIAMOND @@ -645,12 +652,14 @@ void HudLadder :: draw( void ) // TYPE LINE // ATTRIB - ON CONDITION // draw appraoch glide slope marker +#ifdef ENABLE_SP_FMDS if (glide_slope_marker) { if (ihook) { Line(-half_span+15, (glide_slope-actslope)*factor, -half_span + hole, (glide_slope-actslope)*factor); Line(half_span-15, (glide_slope-actslope)*factor, half_span - hole, (glide_slope-actslope)*factor); } }// if glide_slope_marker +#endif } TextList.draw(); @@ -670,6 +679,7 @@ void HudLadder :: draw( void ) glPopMatrix(); //************************************************************* //************************************************************* +#ifdef ENABLE_SP_FMDS if(waypoint_marker) { //waypoint marker computation float fromwp_lat,towp_lat,fromwp_lon,towp_lon,dist,delx,dely,hyp,theta,brg; @@ -758,6 +768,7 @@ void HudLadder :: draw( void ) } //brg<12 } // if waypoint_marker +#endif }//draw /******************************************************************/ diff --git a/src/Instrumentation/instrument_mgr.cxx b/src/Instrumentation/instrument_mgr.cxx index 57e1ebae7..b41189640 100644 --- a/src/Instrumentation/instrument_mgr.cxx +++ b/src/Instrumentation/instrument_mgr.cxx @@ -25,7 +25,7 @@ #include "dme.hxx" #include "gps.hxx" #include "heading_indicator.hxx" -#include "kr_87.cxx" +#include "kr_87.hxx" #include "mag_compass.hxx" #include "slip_skid_ball.hxx" #include "turn_indicator.hxx" -- 2.39.5