today, when developing an Android project, you need to export the JNI C header file from the class file generated by the Android project with the Javah command, but the error is as follows:
Figure 1
Figure 2
First correct the error in 11: Under Windows CMD window, use CD f:\...\ ... Such a command cannot be located to the f:\...\ ... Directory, you must first enter F:, and then press ENTER to enter the f:\...\ ... Directory.
For the error in Figure 2, I refer to this article: http://blog.csdn.net/hejinjing_tom_com/article/details/8125648, but according to his method will still error, such as:
Later checked the use of the Javah command, and refer to the blog: http://www.cnblogs.com/kissazi2/p/3298884.html, finally successfully exported the JNI C language header file, such as:
Summary: Javah-classpath should be used for loading class paths, such as my f:\ personal project \ Parking Butler \ License Plate Recognition Module \carrecognition\carplate\bin\classes, Instead of the previously mentioned Jar path for the Android SDK. -D followed by the location of the generated header file we specified, here I am f:/, is under the F packing directory.
Sometimes a small problem will toss half a day, I hope my summary is helpful to everyone.
Common errors and correct usage of exporting class header files with Javah