T
tony_lincoln
Dear friends,
I tried to call c++ codes from Java, so I used JNI:
Following the instruction of java JNI official website, I succeeded in
calling HelloWorld.cpp from Java.
However, when I tried to call my C++ calculation which is called
calcBE, there is one error:
E:\>Java Measure
Exception in thread "main" java.lang.UnsatisfiedLinkError: calcBE
at SimilarityMeasure.calcBE (native method)
at SimilarityMeasure.main(SimilarityMeasure.java:42)
I tried to compiled the C++ codes and got different dll files for
several times, but the result is the same: always the error mentioned
above.
In JNI HelloWorld, if there is error, it will be like this:
Exception in thread "main" java.lang.UnsatisfiedLinkError: no hello in
java.library.path. So I know that I have to set the path.
But the error I mentioned above has no enough information----I do not
know if I did not compile the C++ codes in a correct way, or if there
are other things wrong.
THank you in advance.
tony
I tried to call c++ codes from Java, so I used JNI:
Following the instruction of java JNI official website, I succeeded in
calling HelloWorld.cpp from Java.
However, when I tried to call my C++ calculation which is called
calcBE, there is one error:
E:\>Java Measure
Exception in thread "main" java.lang.UnsatisfiedLinkError: calcBE
at SimilarityMeasure.calcBE (native method)
at SimilarityMeasure.main(SimilarityMeasure.java:42)
I tried to compiled the C++ codes and got different dll files for
several times, but the result is the same: always the error mentioned
above.
In JNI HelloWorld, if there is error, it will be like this:
Exception in thread "main" java.lang.UnsatisfiedLinkError: no hello in
java.library.path. So I know that I have to set the path.
But the error I mentioned above has no enough information----I do not
know if I did not compile the C++ codes in a correct way, or if there
are other things wrong.
THank you in advance.
tony