This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: troubles with defineClass and Binary Compatibility on ARM-Linux


Philippe Laporte writes:
 > 
 > 
 > Now on ARM,
 > 
 > I do 
 > 
 > 1- ./build-db.sh - this build kf.db using the correct cross-gcj and
 > the x86 FC4 gcj-dbtool (I'm assuming the DB format does not matter
 > across ARCH, although it does matter across GCJ versions - I get
 > java.lang.NoClassDefFoundError if I use the 4.0.2 toolchain to
 > generate a db for 4.2 runtime, even though nm reveals that the
 > symbols are there)

The db format hasn't changed, so I'm rather surprised by that.  

 > I'm using scratchbox with the Nokia 770 fro cross-development. For
 > what is needed here scratchbox is like chroot. Since the paths
 > stored in kf.db are absolute I make sure to put the .so files in
 > the same path in the chroot environment as the one in which they
 > are built.

Yes.  It won't work otherwise.

I suspect your real problem is that the ARM port for libgcj is
incomplete.  I'm no ARM Linux expert, but last time I heard about it
libffi still wasn't done.

Anyway, if I were you I'd be using gdb to find the cause of the null
pointer trap.

 > 2-  arm-unknown-linux-gnu-gcj -findirect-dispatch -Wl,-Bsymbolic -fjni
 > -lgij framework.jar -o kf
 > 
 > 3- ./kf -Dgnu.gcj.precompiled.db.path=kf.db -verbose:class -jar
 > framework.jar -init
 > 
 > 
 > With the gcc-4.2-20060617-glibc-2.3.2/arm-unknown-linux-gnu toolchain,
 > 
 > [Loaded (BC-compiled) org.knopflerfish.framework.BundleImpl from <no
 > code source>]
 > [Loaded (pre-compiled) org.osgi.framework.Bundle from <no code source>]
 > [Loaded (BC-compiled) org.knopflerfish.framework.Debug from <no code
 > source>]
 > [Loaded (pre-compiled) java.lang.InterruptedException from <no code
 > source>]
 > [Loaded (pre-compiled) java.lang.NumberFormatException from <no code
 > source>]
 > [Loaded (pre-compiled) java.net.MalformedURLException from <no code
 > source>]
 > [Loaded (pre-compiled) java.lang.NoClassDefFoundError from <no code
 > source>]
 > [Loaded (pre-compiled) java.lang.LinkageError from <no code source>]
 > Exception in thread "main" [Loaded (pre-compiled) java.lang.Throwable
 > $StaticData from <no code source>]
 > java.lang.NullPointerException
 >    <<No stacktrace available>>
 > 
 > How can I get more debug info, like a stacktrace?

Use gdb.

Andrew.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]