androidandroid-ndkjnetpcap

Using Android NDK for JnetPcap library


I' m new user in 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. I copy the JNI folder in my project, but I can't use the classes of JnetPcap Library.


Solution

  • 1) Create a new Android project in eclipse.

    2) Copy the jni folder from the already compiled project to the new android project.

    3) Copy org folder that contains JnetPcap Library from src to src of the new android project.

    4) Right click in the new android project: Android Tools -> Add native support...