Solved

JNI- invoking problem: UnsatisifedLinkError

Posted on 2004-04-17
3
257 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
3 Comments
 
LVL 2

Accepted Solution

by:
timbauer earned 150 total points
Comment Utility
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

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
This video teaches viewers about errors in exception handling.

772 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now