Top "Java-native-interface" questions

The Java Native Interface (JNI) gives both the ability for JVM implementations to run system native code and the ability for native code to run Java code (by creating new JVM instances).

How to add a system service to the Android Framework

I want to add my own framework code that runs in the Android "system_server" (handles all the system level …

android java-native-interface android-source
System.loadLibrary does not work. UnsatisfiedLinkError for the second lib in chain

I have java program Client.class that uses cpp shared library libclient.so via JNI. libclient.so is built as …

java java-native-interface loadlibrary unsatisfiedlinkerror java.library.path
JNI - native method with ByteBuffer parameter

I've got a method: public native void doSomething(ByteBuffer in, ByteBuffer out); Generated by javah C/C++ header of this …

java c java-native-interface bytebuffer
Why I should not reuse a jclass and/or jmethodID in JNI?

This is a question related to a previous post, but this post was solved and now I wanted to change …

java java-native-interface
How to solve Android Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid xxxxx (Thread-X)?

I'm using Opencv sdk for Android to develop a real time processing and matching. The main Opencv traitment logic is …

android android-ndk java-native-interface segmentation-fault opencv4android
How to check if a file is readable?

I'm writing Java 6 application and I have to check if a file is readable. However, on Windows canRead() always returns …

java winapi java-native-interface jna
Linking static library with JNI

Java versions prior Java 8 requires native code to be in a shared library, but I've read that with Java 8 it's …

java java-native-interface static-libraries java-8 static-linking
Could not find method externalNativeBuild() for arguments

i'm trying to integrate the ndkBuild functionality into an existing android studio project, using the new android studio 2.2 , in order …

android-ndk java-native-interface build.gradle ndk-build android-studio-2.2
Import existing c++ library (.a or .so file) ndk android

I just gone through native development in android. I am successful in getting my AndroidStudio 2.2.2 ready for native debelopment I …

android android-ndk java-native-interface .a .so