Exception in thread "main" java.lang.UnsatisfiedLinkError: xxx()V

Exception in thread "main" java.lang.UnsatisfiedLinkError: com.vipsoft.demo.JNIDemo.testHello()V
    at com.vipsoft.demo.JNIDemo.testHello(Native Method)
    at com.vipsoft.demo.JNIDemo.main(JNIDemo.java:10)

Process finished with exit code 1

是因为java 程序在调用dll时候,不能找到native method 方法的实现。

主要是因为在dll中,可能xxx.h头文件中的接口名和xxx.cpp源文件中的实现函数名不一致导致的。

 

posted @ 2021-12-02 14:05  VipSoft  阅读(1597)  评论(0编辑  收藏  举报