Skip to main content

VM Library Path resolution in mpeenv.ini

3 replies [Last post]
amirn
Offline
Joined: 2009-05-06
Points: 0

I am in the process of porting the OCAP-RI stack to a Linux X86 platform.
This is just an experiment and right now and I am *not* using the RI-Platform. I intend to use my own client simulator.

I wanted some clarifications regarding how paths are resolved by the stack when looking for libraries.

When I launch the stack, the PhoneME VM tries to load the libmpe_g.so and fails because it cannot find it.

My VM options are the following:
VMOPT.1=-Djava.library.path=../bin
VMOPT.2=-Djava.home=cvm
VMOPT.3=-Xlinenum
VMOPT.4=-Xmx20m
VMOPT.5=-Dfile.encoding=ISO8859_1
VMOPT.6=-Djava.ext.dirs=ext

The stack is launched from a linux executable that I copied in $OCAPROOT/bin/$OCAPTC/env

The library path points to ../bin which is where libmpe_g.so is generated.
I tried to add the library to my LD_LIBRARY_PATH, but this didn't resolved the problem.

Any ideas what I could be missing?

Thanks.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
greg80303
Offline
Joined: 2008-07-03
Points: 0

If you are building your stack/JVM from the trunk repository, please note that I made some modifications to how the JVM loads libraries (both JNI and tools libs). See this mailing list post for more details:

https://ocap-ri.dev.java.net/servlets/ReadMsg?list=dev&msgNo=15

Also, all relative filesystem paths are relative to FS.DEFSYSDIR as defined in mpeenv.ini. So, make sure you have that defined correctly.

amirn
Offline
Joined: 2009-05-06
Points: 0

I am not using the latest version of the OCAP-RI stack (still using MR2 PhoneME).
My OCAP-RI build generates a libmpe_g.so as expected by the PhoneME vm.

I am going to use the latest from the trunk and see if this makes a difference.

Right now I am setting FS.DEFSYSDIR=.

amirn
Offline
Joined: 2009-05-06
Points: 0

I fixed my problem by setting FS.DEFSYSDIR=../env
I can now launch the stack.