Re: Porting Sable VM to SH4

Vincent Verstraete <[email protected]> Fri, 27 Oct 2006 17:39:36 +0200
Newsgroups gmane.comp.java.vm.sablevm.devel
Message-ID <[email protected]>
Hello,

The problem is solved by adding 
--property="java.library.path=/usr/local/sablevm/lib/sablevm-classpath" 
as command line argument when invoking the sablevm command. I guess the 
internal java.library.path was wrongly configured somewhere along the 
road. When I compile a simple test program, it runs now.

However, my main goal was to get an OSGI framework (more specifically 
knopflerfish) running on my target sh4 machine. When starting the 
framework, it loads, but I do (sometimes) get an error when installing 
some extra bundles. As it does seem more VM related than OSGI related, I 
thought someone here might know what causes this error. The weird thing 
is, it does not always occur, so my guess is it has something to do with 
Thread scheduling:


java.lang.InternalError
   at java.lang.VMThread.nativeStart (VMThread.java)
   at java.lang.VMThread.start (VMThread.java:322)
   at java.lang.VMThread.create (VMThread.java:165)
   at java.lang.Thread.start (Thread.java:879)
   at org.mcdp.client.channelsocket.Channel_SocketImpl.start 
(Channel_SocketImpl.java:59)
   at org.mcdp.client.channeltracker.bundle.ChannelTracker.addingService 
(ChannelTracker.java:28)
   at org.osgi.util.tracker.ServiceTracker$1.serviceChanged 
(ServiceTracker.java:267)
   at org.knopflerfish.framework.Listeners$3.run (Listeners.java:301)
   at java.security.AccessController.doPrivileged (AccessController.java:96)
   at org.knopflerfish.framework.Listeners.serviceChanged 
(Listeners.java:299)
   at org.knopflerfish.framework.Services.register (Services.java:141)
   at org.knopflerfish.framework.BundleContextImpl.registerService 
(BundleContextImpl.java:273)
   at org.mcdp.client.channelsocket.EEN.Activator.start (Activator.java:38)
   at org.knopflerfish.framework.BundleImpl$1.run (BundleImpl.java:281)
   at java.security.AccessController.doPrivileged 
(AccessController.java:154)
   at org.knopflerfish.framework.BundleImpl.start (BundleImpl.java:255)
   at org.knopflerfish.framework.Framework.startBundle (Framework.java:453)
   at org.knopflerfish.framework.Main.handleArgs (Main.java:305)
   at org.knopflerfish.framework.Main.main (Main.java:190)
   at java.lang.VirtualMachine.invokeMain (VirtualMachine.java)
   at java.lang.VirtualMachine.main (VirtualMachine.java:108)


Anyone who knows the cause of this error (or even better: a solution)?

Cheers,

Vincent



Chris Pickett wrote:

> Hi Vincent,
>
> Vincent Verstraete wrote:
>
>> java.lang.UnsatisfiedLinkError: Native library `javanio' not found 
>> (as file `libjavanio') in gnu.classpath.boot.library.path and 
>> java.library.path
>> [verbose gc: total gc time = 0 sec 0 usec]
>>
>>
>> The weird thing is I do find libjavanio on my system in 
>> /usr/local/sablevm/lib/sablevm-classpath/
>>
>> Any idea where this dynamic linking goes wrong?
>
>
> I hit the same thing last night using a system with gcc-4.0.  I moved 
> to an older system with gcc-3.3 and it went away.  I did hear a report 
> of SableVM "not working" with gcc-4.0, but there weren't any further 
> details.  I can't say for sure what the problem is, it might be gcc, 
> it might be something like libtool, it might be an environment 
> variable. If I figure it out, I'll let you know; please do the same.  
> Note that for what I need now, I'm fine just using gcc-3.3, so I 
> probably won't spend a lot of time on it.
>
> Cheers,
> Chris
>
> _______________________________________________
> SableVM-devel mailing list
> [email protected]
> http://sablevm.org/lists/control/listinfo/sablevm-devel