[kaffe] Seg Fault on Embedded System

Rafael Teixeira monoman at gmail.com
Sun Oct 1 10:10:58 PDT 2006


Is your target based on Snapgear, with uclibc?

My experience is that there is some bug in the pthreads
implementation, and I had to put the second thread in the limbo,
because it comes with the same PID or SID of the main thread, leading
to problems in the synchronization and so stopping everything or
problems on unintended sharing of thread-level-storage generating
segmentation faults or, sometimes, exceptions.

:(


On 9/29/06, Kevin DeVries <kevin at verticalpower.com> wrote:
>
>
>
>
> Lowdown: creating cross-compiled kaffe for embedded xscale (arm) processor;
> running java/kaffe on target generates Seg Fault on simple (any) java
> program
>
>
>
> Kaffe version: 1.1.7
>
> Host machine: x86-linux (2.4.32)
>
> Target machine: arm-linux (2.6.17)
>
>
>
> General process:
>
>
>
> host%untar'ed kaffe-1.1.7
>
> host%mkdir native
>
> host%mkdir arm
>
> host%cd native; make config; make; make install
>
> <success>
>
> host%cd arm
>
> host%CC=<xgcc> NM=<xnm> AR=<xar> ../kaffe-1.1.7/configure –host=arm-linux
> –build=i686-linux –disable-native-awt –disable-xawt-xi18n
> –without-kaffe-qt-awt –disable-gtk-peer –prefix=/opt/kaffe/arm
> –disable-sound
>
> <success; 11th time is the charm>
>
> host% make; make install
>
> <success>
>
>
>
> host% <copy server:/opt/kaffe/arm to target:/opt/kaffe/arm>
>
>
>
> Hello.java:
>
> public class Hello
>
> {
>
>   public static void main (String[] argv)
>
>   {
>
>      int i=1;         // I've even tried without this line
>
>   }
>
> }
>
>
>
> host% javac Hello
>
> host% <copy Hello.class to target>
>
>
>
> target% java Hello
>
> Segmentation Fault
>
> target% java –v Hello
>
>>
> Loading
> java/util/Comparator.class(/opt/kaffe/arm/jre/lib/glibj.zip)
> [compressed]
>
> Segmentation Fault
>
>
>
> host% java Hello
>
> host% <no segv>
>
>
>
> I've tried both a standard distribution of javac and the kaffe distribution
> of javac and got the same results.
>
> And I can (obviously) run a cross-compiled executable on my target.
>
>
>
> Anything that I should take a look at? The only thing I can think of is that
> it's not finding a library or that a library is out of sync. I don't have a
> debugger on the target @ this time, so heading down that path is do-able,
> just a lot of effort that I'm not ready for.
>
>
>
> Thanks much,
>
>
>
> Kevin DeVries
>
> Vertical Power
>
> 317 Commercial St NW
>
> Albuquerque, NM 87102
>
> 505 241 9333 (c)/(w)
>
>
>
>
> _______________________________________________
> kaffe mailing list
> kaffe at kaffe.org
> http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
>
>
>


-- 
Rafael "Monoman" Teixeira
---------------------------------------
"The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man." George Bernard Shaw


More information about the kaffe mailing list