简体   繁体   English

将Android NDK用于JnetPcap库

[英]Using Android NDK for JnetPcap library

I' m new user in Android NDK. 我是Android NDK的新用户。 I want to use the JnetPcap library in one android project and i have already found an another project that has contained the JNI folder with the JnetPcap library and other files, such as Android.mk. 我想在一个Android项目中使用JnetPcap库,并且我已经找到了另一个项目,其中包含Jnet文件夹以及JnetPcap库和其他文件,例如Android.mk。 I copy the JNI folder in my project, but I can't use the classes of JnetPcap Library. 我在项目中复制了JNI文件夹,但无法使用JnetPcap库的类。

1) Create a new Android project in eclipse. 1)在eclipse中创建一个新的Android项目。

2) Copy the jni folder from the already compiled project to the new android project. 2)将jni文件夹从已编译的项目复制到新的android项目。

3) Copy org folder that contains JnetPcap Library from src to src of the new android project. 3)将包含JnetPcap库的org文件夹从src复制到新的android项目的src。

4) Right click in the new android project: Android Tools -> Add native support... 4)右键单击新的android项目:Android工具->添加本机支持...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM