Package: flightgear
Severity: normal
Tags: patch

When building 'flightgear' on amd64 with gcc-4.0,
I get the following error:

g++ -DHAVE_CONFIG_H -I. -I. -I../../src/Include -I../.. -I../../src  
-I/usr/X11R6/include -I/usr/local//include   -c -o input.o `test -f input.cxx 
|| echo './'`input.cxx
input.cxx:547: error: non-local variable '<anonymous struct> mouse_cursor_map 
[]' uses anonymous type
make[3]: *** [input.o] Error 1
make[3]: Leaving directory `/flightgear-0.9.5/src/Input'

With the attached patch 'flightgear' can be compiled
on amd64 using gcc-4.0.

Regards
Andreas Jochens

diff -urN ../tmp-orig/flightgear-0.9.5/src/Input/input.cxx ./src/Input/input.cxx
--- ../tmp-orig/flightgear-0.9.5/src/Input/input.cxx    2004-07-06 
18:02:01.000000000 +0200
+++ ./src/Input/input.cxx       2005-02-02 21:05:24.047726908 +0100
@@ -541,7 +541,7 @@
 // cursors defined as textures referenced in the property tree.  This
 // list could then be eliminated. -Andy
 //
-struct {
+static struct {
   const char * name;
   int cursor;
 } mouse_cursor_map[] = {
diff -urN ../tmp-orig/flightgear-0.9.5/src/Scripting/NasalSys.cxx 
./src/Scripting/NasalSys.cxx
--- ../tmp-orig/flightgear-0.9.5/src/Scripting/NasalSys.cxx     2004-06-01 
22:48:45.000000000 +0200
+++ ./src/Scripting/NasalSys.cxx        2005-02-02 21:11:30.396847443 +0100
@@ -86,7 +86,7 @@
 
     char buf[256];
     if(!name) {
-        sprintf(buf, "[EMAIL PROTECTED]", (int)script);
+        sprintf(buf, "[EMAIL PROTECTED]", (long)script);
         name = buf;
     }
 
diff -urN ../tmp-orig/flightgear-0.9.5/src/Scripting/nasal-props.cxx 
./src/Scripting/nasal-props.cxx
--- ../tmp-orig/flightgear-0.9.5/src/Scripting/nasal-props.cxx  2004-04-05 
17:06:22.000000000 +0200
+++ ./src/Scripting/nasal-props.cxx     2005-02-02 21:11:57.606583312 +0100
@@ -213,7 +213,7 @@
     return propNodeGhostCreate(c, globals->get_props());
 }
 
-struct {
+static struct {
     naCFunction func;
     char* name;
 } propfuncs[] = {


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to