EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Android version LOAD ERROR

Also by EldoS: CallbackDisk
Create virtual disks backed by memory or custom location, expose disk images as disks and more.
Posted: 06/21/2016 21:37:52
by xu zhang (Basic support level)
Joined: 06/21/2016
Posts: 1

when I load the libjnisolfs.so using System.loadLibrary("jnisolfs"); The error comes:
06-22 09:33:17.530: A/art(6294): art/runtime/java_vm_ext.cc:410] JNI DETECTED ERROR IN APPLICATION: JNI FindClass called with pending exception java.lang.ClassNotFoundException: Didn't find class "eldos.solfs.SolFSStorage" on path: DexPathList

How to solve this´╝č
Posted: 06/22/2016 02:26:55
by Eugene Mayevski (Team)

Thank you for contacting us.

jnisolfs.so is an interface between the Java class and the native library.

If you are using Java API, then you need to add the corresponding JAR file to your project, use SolFSStorage class, and it will load the JNI library for you.

If you are trying to use SolFS from C code, then you don't need jnisolfs.so.

In both cases you need to deploy solfs.so (I am talking not about jnisolfs.so now) with your project.

Please see "Using Java library" topic in the help file as well: https://www.eldos.com/documentation/so..._java.html

Sincerely yours
Eugene Mayevski
Posted: 06/22/2016 13:45:14
by Hao Wu (Standard support level)
Joined: 06/21/2016
Posts: 4

Thanks for your reply.

Where can we get the solfs.so? We didn't find it in the downloaded package.
Posted: 06/22/2016 14:02:06
by Eugene Mayevski (Team)

I apologize for misleading you, but currently the SolFS engine is built into libjnisolfs.so , without a separate solfs.so .

Before we move further, could you please tell us, if you plan to use SolFS on Android from Java code or from C code?

Sincerely yours
Eugene Mayevski
Posted: 06/22/2016 15:16:51
by Hao Wu (Standard support level)
Joined: 06/21/2016
Posts: 4

We want to use C code on Android. Thanks.
Posted: 06/22/2016 15:35:05
by Alexander Plas (Team)

When you make System.loadLibrary call, Java loads not simple library but JNI library. Java first loads the library and then calls JNI_OnLoad function in the library. JNI_OnLoad function tries to register native methods implemented by the library. Java should link native methods to classes. You haven't used our JAR file with SolFS Java classes. So, registration of native methods fails since Java unable to find SolFS Java classes.
Posted: 06/22/2016 15:39:40
by Eugene Mayevski (Team)

To add to Alexander's explanation - you don't need to load libjnisolfs the way you did it, if you want to use SolFS from C in Android. I am currently updating the installation so that it would include .a files for static linkage of SolFS engine to your C code. I will let you know once the downloads are available.

Sincerely yours
Eugene Mayevski
Posted: 06/22/2016 16:09:43
by Eugene Mayevski (Team)

We've updated the downloads (both on the public page and in My Control Center. The date is today's one, the version has not been changed (as there were no changes in code).

What we've added is libsolfs.a files in /Lib/Android directory. They are linked statically to your SolFS project. Also you can use the source code in /CPP directory to build C++ classes around libsolfs.a and use that SolFS classes.

There are instructions available in the help file.

Sincerely yours
Eugene Mayevski
Posted: 06/22/2016 22:10:23
by Hao Wu (Standard support level)
Joined: 06/21/2016
Posts: 4

Thanks very much for your quick update.

Here is another question.
We use the libsolfs.a and run the program on android phone, when we are calling StorageOpen() function to open a storage file, the program will crash. But use access() function there is no problem. There is also no problem when we use .so. What permission does the StorageOpen() function need when running on Android?
Posted: 07/06/2016 17:37:20
by Eugene Mayevski (Team)

I apologize for not answering the question - probably it has been overlooked in the mail flow.

Is the question still relevant or you've sorted it out in our HelpDesk or yourself?

Sincerely yours
Eugene Mayevski
Also by EldoS: CallbackRegistry
A component to monitor and control Windows registry access and create virtual registry keys.



Topic viewed 12348 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS business operates as a division of /n software, inc. For more information, please read the announcement.

Got it!