Android NDK generates the C/C ++ header file in eclipse, androidndk
We know that in Android NDK development, it is complicated and redundant to make the native function name and parameter list consistent with the original definition of the java class file, because JDK comes with a command line tool named javah to execute tasks, javah can parse Java class files for native methods and generate header files composed of native method declarations. However, switching back and forth to the command terminal during development is cumbersome. Today's blog post will explain how to generate header files in eclipse.
(1) Open Eclipse IDE and choose Run | External Tools deployments from the top menu bar. in the External Tools deployments dialog box, select Program, click the New launch configuration button, click the Main tab, and fill in the configuration as shown in figure (1:
Figure (1)
(2) switch to The Refresh tab, select the Refresh resource upon completion check box, and select The project containing the selected resource in The list, as shown in (2:
Figure (2)
(3) switch to the Common tab, and select the check box External Tools under the Display in favorites menu group, as shown in (3:
Figure (3)
Click OK to save the external tool configuration. So far, the method for generating the C/C ++ header file in eclipse has been configured.
The testing process is as follows:
Note: $ {env_var: D: \ AndroidSdk_x86_64 \ sdk}. replace this with your own sdk path.
Reprinted please indicate the source: http://blog.csdn.net/android_jiangjun/article/details/45104581