Re: [Flightgear-devel] Simgear commit breaks Atlas (ot??)

2012-10-15 Thread ThorstenB
 FYI the Atlas configure.ac will use -lSimGearCore if ENABLE_SIMGEAR_SHARED
 is set to yes, which is misleading. I will change this to something more
 more useful (Suggestion?).

I added ENABLE_SIMGEAR_SHARED to Atlas some time last year, since the 
libraries SimGearCore and SimGearScene (the latter isn't required for 
Atlas) were only built when the ENABLE_SIMGEAR_SHARED switch was set 
for SimGear - so the options for SimGear and Atlas matched exactly.

Since 2.9.0 SimGear always builds two libraries only (instead of the 
earlier 9 or 10 different libs), no matter whether static or shared libs 
were selected for SimGear. So indeed, the option should be renamed now. 
Also, the default should be changed - since SimGearCore is now always 
provided by latest (and future) SimGear.

Suggestion: rename the switch to SIMGEAR_LEGACY and invert the logic, 
so it can be set when building with old SimGear versions.

cheers,
Thorsten


--
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Simgear commit breaks Atlas (ot??)

2012-10-14 Thread Frederic Bouvier
t1.update( SGGeod::fromRad(lon, lat), 0, 0 );

There is also SGGeod::fromDeg to avoid the multiply by SGD_DEGREES_TO_RADIANS

Regards,
-Fred

- Mail original -
 De: Alasdair Campbell ali...@btinternet.com
 À: FlightGear devel flightgear-devel@lists.sourceforge.net
 Envoyé: Dimanche 14 Octobre 2012 18:26:54
 Objet: [Flightgear-devel] Simgear commit breaks Atlas (ot??)
 
 After SGTime: use SGGeod, quieter init. (James Turner
 89d30acbc5040bf36a3329fcb21789d2855fa6d3)
 Atlas build (misc.cxx) fails at:
 
 double magneticVariation(double lat, double lon, double elev)
 {
 SGTime t1;
 
 lon *= SGD_DEGREES_TO_RADIANS;
 lat *= SGD_DEGREES_TO_RADIANS;
 t1.update(lon, lat, 0, 0);
 
 return sgGetMagVar(lon, lat, elev, t1.getJD()) *
 SGD_RADIANS_TO_DEGREES;
 }
 
 Can I get a suggestion to update this code in my local repo to:
   t1.update( const SGGeod location, time_t ct, long int warp )
 Sorry, my c++ is so really rusty.
 
 Alasdair
 
 --
 Don't let slow site performance ruin your business. Deploy New Relic
 APM
 Deploy New Relic app performance management and know exactly
 what is happening inside your Ruby, Python, PHP, Java, and .NET app
 Try New Relic at no cost today and get our sweet Data Nerd shirt too!
 http://p.sf.net/sfu/newrelic-dev2dev
 ___
 Flightgear-devel mailing list
 Flightgear-devel@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/flightgear-devel
 

--
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Simgear commit breaks Atlas (ot??)

2012-10-14 Thread Alasdair Campbell
On Sun, 14 Oct 2012 20:47:01 +0200 (CEST)
Frederic Bouvier fredfgf...@free.fr wrote:

 t1.update( SGGeod::fromRad(lon, lat), 0, 0 );
 
 There is also SGGeod::fromDeg to avoid the multiply by SGD_DEGREES_TO_RADIANS
 
 Regards,
 -Fred
 
 - Mail original -
  De: Alasdair Campbell ali...@btinternet.com
  À: FlightGear devel flightgear-devel@lists.sourceforge.net
  Envoyé: Dimanche 14 Octobre 2012 18:26:54
  Objet: [Flightgear-devel] Simgear commit breaks Atlas (ot??)
  
  After SGTime: use SGGeod, quieter init. (James Turner
  89d30acbc5040bf36a3329fcb21789d2855fa6d3)
  Atlas build (misc.cxx) fails at:
  
  double magneticVariation(double lat, double lon, double elev)
  {
  SGTime t1;
  
  lon *= SGD_DEGREES_TO_RADIANS;
  lat *= SGD_DEGREES_TO_RADIANS;
  t1.update(lon, lat, 0, 0);
  
  return sgGetMagVar(lon, lat, elev, t1.getJD()) *
  SGD_RADIANS_TO_DEGREES;
  }
  
  Can I get a suggestion to update this code in my local repo to:
  t1.update( const SGGeod location, time_t ct, long int warp )
  Sorry, my c++ is so really rusty.
  
  Alasdair
  


Thank you Fred. I had tried something similar, but your suggestion still gives 
link error:

g++  -g -O2 -DFGBASE_DIR='NONE/lib/FlightGear'  -L/usr/local//lib -o Atlas 
Notifications.o Atlas.o GLUTWindow.o AtlasBaseWindow.o AtlasWindow.o 
AtlasController.o FlightTrack.o Image.o NavData.o Overlays.o AirportsOverlay.o 
AirwaysOverlay.o FixesOverlay.o NavaidsOverlay.o FlightTracksOverlay.o 
CrosshairsOverlay.o RangeRingsOverlay.o Tiles.o TileMapper.o Searcher.o 
Search.o Preferences.o Graphs.o Culler.o Scenery.o Background.o Cache.o 
LayoutManager.o Bucket.o Subbucket.o Palette.o misc.o Globals.o Geographics.o 
-lsgmagvar -lsgtiming -lsgmisc -lsgio -lsgserial -lsgdebug -lsgbucket 
-lsgstructure -lsgmath -lsgthreads -lplibsg -lplibpuaux -lplibpu -lplibfnt 
-lplibnet -lglut -lGLU -lGL -lXmu -lXt -lSM -lICE -lXi -lXext -lX11 -lpthread 
-lrt -lm  -lpng -lz -ljpeg -lGLEW -lplibul -lcurl -lrt -lm 
misc.o: In function `magneticVariation(double, double, double)':
/home/alasdair/Desktop/Atlas/src/misc.cxx:405: undefined reference to 
`SGTime::update(SGGeod const, long, long)'
collect2: error: ld returned 1 exit status
make[3]: *** [Atlas] Error 1

I am pulling my hair out:( 
Do I need to link against another sg library?

Kind regards,
Alasdair




--
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Simgear commit breaks Atlas (ot??)

2012-10-14 Thread Frederic Bouvier
 De: Alasdair Campbell ali...@btinternet.com
 
 On Sun, 14 Oct 2012 20:47:01 +0200 (CEST)
 Frederic Bouvier fredfgf...@free.fr wrote:
 
  t1.update( SGGeod::fromRad(lon, lat), 0, 0 );
  
  There is also SGGeod::fromDeg to avoid the multiply by
  SGD_DEGREES_TO_RADIANS
  
  Regards,
  -Fred
  
  - Mail original -
   De: Alasdair Campbell ali...@btinternet.com
   À: FlightGear devel flightgear-devel@lists.sourceforge.net
   Envoyé: Dimanche 14 Octobre 2012 18:26:54
   Objet: [Flightgear-devel] Simgear commit breaks Atlas (ot??)
   
   After SGTime: use SGGeod, quieter init. (James Turner
   89d30acbc5040bf36a3329fcb21789d2855fa6d3)
   Atlas build (misc.cxx) fails at:
   
   double magneticVariation(double lat, double lon, double elev)
   {
   SGTime t1;
   
   lon *= SGD_DEGREES_TO_RADIANS;
   lat *= SGD_DEGREES_TO_RADIANS;
   t1.update(lon, lat, 0, 0);
   
   return sgGetMagVar(lon, lat, elev, t1.getJD()) *
   SGD_RADIANS_TO_DEGREES;
   }
   
   Can I get a suggestion to update this code in my local repo to:
 t1.update( const SGGeod location, time_t ct, long int warp )
   Sorry, my c++ is so really rusty.
   
   Alasdair
   
 
 
 Thank you Fred. I had tried something similar, but your suggestion
 still gives link error:
 
 g++  -g -O2 -DFGBASE_DIR='NONE/lib/FlightGear'  -L/usr/local//lib
 -o Atlas Notifications.o Atlas.o GLUTWindow.o AtlasBaseWindow.o
 AtlasWindow.o AtlasController.o FlightTrack.o Image.o NavData.o
 Overlays.o AirportsOverlay.o AirwaysOverlay.o FixesOverlay.o
 NavaidsOverlay.o FlightTracksOverlay.o CrosshairsOverlay.o
 RangeRingsOverlay.o Tiles.o TileMapper.o Searcher.o Search.o
 Preferences.o Graphs.o Culler.o Scenery.o Background.o Cache.o
 LayoutManager.o Bucket.o Subbucket.o Palette.o misc.o Globals.o
 Geographics.o -lsgmagvar -lsgtiming -lsgmisc -lsgio -lsgserial
 -lsgdebug -lsgbucket -lsgstructure -lsgmath -lsgthreads -lplibsg
 -lplibpuaux -lplibpu -lplibfnt -lplibnet -lglut -lGLU -lGL -lXmu
 -lXt -lSM -lICE -lXi -lXext -lX11 -lpthread -lrt -lm  -lpng -lz
 -ljpeg -lGLEW -lplibul -lcurl -lrt -lm
 misc.o: In function `magneticVariation(double, double, double)':
 /home/alasdair/Desktop/Atlas/src/misc.cxx:405: undefined reference to
 `SGTime::update(SGGeod const, long, long)'
 collect2: error: ld returned 1 exit status
 make[3]: *** [Atlas] Error 1
 
 I am pulling my hair out:(
 Do I need to link against another sg library?

Simgear library naming changed recently. -lsgmagvar -lsgtiming -lsgmisc -lsgio 
-lsgserial -lsgdebug -lsgbucket -lsgstructure -lsgmath -lsgthreads
are gone and should be replaced by -lSimGearCore -lSimGearScene

Regards,
-Fred

--
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Simgear commit breaks Atlas (ot??)

2012-10-14 Thread Alasdair Campbell
On Sun, 14 Oct 2012 23:24:29 +0200 (CEST)
Frederic Bouvier fredfgf...@free.fr wrote:
 
 Simgear library naming changed recently. -lsgmagvar -lsgtiming -lsgmisc 
 -lsgio -lsgserial -lsgdebug -lsgbucket -lsgstructure -lsgmath -lsgthreads
 are gone and should be replaced by -lSimGearCore -lSimGearScene
 
 Regards,
 -Fred
 
Problem solved. Many Thanks.
Both my efforts  your suggestion now build OK.
FYI the Atlas configure.ac will use -lSimGearCore if ENABLE_SIMGEAR_SHARED
is set to yes, which is misleading. I will change this to something more
more useful (Suggestion?).

Again, many thanks

Alasdair

--
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel