[fpc-pascal] now i have a very strange behaviour of my arm compiler

Benedikt Schindler BeniSchindler at gmx.de
Tue Apr 28 13:48:30 CEST 2009


Hi,

i still try to get a gtk applicatoins running on my device.
And now i have found a work around for one error message.

But in reality it's not a work around. It's a: "i didn't realy change 
anything, but it works now"
If i delete the changes again, the error raises again.
So maybe someone of you have an idea where the real problem is.

----------------
Original File doesn't work. Error message is:
----------------

(process:24386): GLib-WARNING (recursed) **: gmessages.c:387: could not 
find handler with id `0' for domain ""
aborting...

-----------------
This one works:
-----------------

--- /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc.orig   
Tue Apr 28 10:24:19 2009
+++ /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc        
Tue Apr 28 10:31:57 2009
@@ -302,7 +302,12 @@
       inc(i);
     end;
   end;
+var
+  index : integer;
 begin
+  //delme: just some output for debugging
+  for index := 0 to argc -1 do writeln(argv[index]);
+  // init gtk
   gtk_init(@argc, at argv);
   UseTransientForModalWindows:=not SearchOption('--lcl-no-transient',true);
 end;

----------------------
Also this one works:
----------------------

--- /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc.orig   
Tue Apr 28 10:24:19 2009
+++ /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc        
Tue Apr 28 10:47:25 2009
@@ -302,6 +302,8 @@
       inc(i);
     end;
   end;
+var
+  index : integer;
 begin
   gtk_init(@argc, at argv);
   UseTransientForModalWindows:=not SearchOption('--lcl-no-transient',true);

----------------------
and even this one works:
----------------------

--- /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc.orig   
Tue Apr 28 10:24:19 2009
+++ /media/mmcblk0p3/lazarus/lcl/interfaces/gtk/gtkwidgetset.inc        
Tue Apr 28 11:06:16 2009
@@ -303,6 +303,7 @@
     end;
   end;
 begin
+  writeln(argv[0]);
   gtk_init(@argc, at argv);
   UseTransientForModalWindows:=not SearchOption('--lcl-no-transient',true);
 end;

----------------------
if i delete the variable declaration (or the writeln), i have the error 
again.
Error raises at: gtk_init(@argc, at argv);

Backtrace
-----------------

Starting program: /opt/test/om_test_suite

Program received signal SIGILL, Illegal instruction.
FPC_CPUCODEINIT () at /media/mmcblk0p3/fpc/rtl/arm/arm.inc:596
596         ldrd r0,[r0]
Current language:  auto; currently pascal
(gdb) cont
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0x49534e40 in ?? ()
(gdb) bt
#0  0x49534e40 in ?? ()
#1  0x49534e40 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb) cont
Continuing.

(process:24386): GLib-WARNING (recursed) **: gmessages.c:387: could not 
find handler with id `0' for domain ""
aborting...

Program received signal SIGABRT, Aborted.
0x406d8df4 in raise () from /lib/libc.so.6
(gdb) bt
#0  0x406d8df4 in raise () from /lib/libc.so.6
#1  0x406da3fc in abort () from /lib/libc.so.6
Backtrace stopped: frame did not save the PC
(gdb) cont
Continuing.

Program terminated with signal SIGABRT, Aborted.
The program no longer exists.
(gdb) quit




More information about the fpc-pascal mailing list