Good day, dear friends.
Yesterday I was given a task to introduce native functions in our application. I've never used C/C++ before, but it doesn't matter.
The question is, to generate C header file from Java class.
First of all, I wrote NativeSample.java, compiled it (see in native-sample.zip) and brought compiled file (.class) to $JDK/bin directory.
Then I had tried "javah -jni NativeSample" - but I got this message:
Yesterday I was given a task to introduce native functions in our application. I've never used C/C++ before, but it doesn't matter.
The question is, to generate C header file from Java class.
First of all, I wrote NativeSample.java, compiled it (see in native-sample.zip) and brought compiled file (.class) to $JDK/bin directory.
Then I had tried "javah -jni NativeSample" - but I got this message:
Don't we need C/C++ compiler to generate header file form Java class file?bad class file: .\NativeSample.class
class file contains wrong class: com.dsp.NativeSample