dcsimg
I am getting unsatisfied link error to the method of the dll in Win NT
2 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Gurunathan_Govindan
Posted On:   Saturday, January 5, 2002 10:31 PM

Hi,
I am experimenting with JNI.I wrote an program that calls 2 functions in C++. It is working fine when I do not put the java file in a package. But it says unsatisfied link error to the method in the dll, when I put the java file in a package . I have set the java.library.path to the dll.
Can anyone help me?
Thanks in advance.
Guru

Re: I am getting unsatisfied link error to the method of the dll in Win NT

Posted By:   Ben_Wu  
Posted On:   Wednesday, January 30, 2002 09:26 AM

after you place your java file in the package you need to rerun javah from the package base and recompile your native code with the new function headers generated by javah.

for example this is what your javah generated header looks like before you repackage your java file.


Java_YourClass_YourFunction


after moving your .java file into the correct package directory, rerun javah from the BASE and you'll get the following.


Java_com_yourco_YourClass_YourFunction


that should solve your problems.


cheers.
-ben

Re: I am getting unsatisfied link error to the method of the dll in Win NT

Posted By:   The_Lion  
Posted On:   Monday, January 7, 2002 12:47 PM

Did you add the package name in the native functions signature ?
About | Sitemap | Contact