Solved

JNI- invoking problem: UnsatisifedLinkError

Posted on 2004-04-17
3
263 Views
Last Modified: 2012-08-13

Hi,
I am using the JNI to load a shared library in C++ which has got reference to other C++ libraries. I am getting the following error while doing so.

/data2/usr/pvcs/cms_ac/cms/deliver/lib/libcreditdb.so: ld.so.1: /bin/../java/bin/../bin/sparc/native_threads/java: fatal: relocation error: file /data2/usr/pvcs/cms_ac/cms/deliver/lib/libcreditdb.so: symbol __1cLUtsDateTimeG__vtbl_: referenced symbol not found
java.lang.UnsatisfiedLinkError: /data2/usr/pvcs/cms_ac/cms/deliver/lib/libcreditdb.so: ld.so.1: /bin/../java/bin/../bin/sparc/native_threads/java: fatal: relocation error: file /data2/usr/pvcs/cms_ac/cms/deliver/lib/libcreditdb.so: symbol __1cLUtsDateTimeG__vtbl_: referenced symbol not found
        at java.lang.ClassLoader$NativeLibrary.load(Native Method)
        at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1382)
        at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1306)
        at java.lang.Runtime.loadLibrary0(Runtime.java:749)
        at java.lang.System.loadLibrary(System.java:820)
        at CreditEngineService.<clinit>(CreditEngineService.java:69)
        at CreditEngineInterface.main(CreditEngineInterface.java:40)
0
Comment
Question by:kanuaravind
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 2

Accepted Solution

by:
timbauer earned 150 total points
ID: 10853009
The poblem appears to be that loadLibrary cannot find the entry point it is looking for.
The native library was probably compiled incorrectly.
Make sure the function you are going to call is wrapped in an extern "C" block.


0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question