0

I Pasted .so file into my new project folder

jniLibs->arm64-v8a  
jniLibs->armeabi-v7a

Inside MainActivity.java file I declared

static {
        System.loadLibrary("filename");
    }

@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        TextView textView = findViewById(R.id.textView);
        try {
           textView.setText(METHODNAME("string")+"");
        } catch (Exception e) {
           Log.i("error", e.message());
        }
    }

public static native int[] METHODNAME(String strng);

When I run the app it shows below error

java.lang.UnsatisfiedLinkError: No implementation found for int[] com.android.myapp.MainActivity.METHODNAME(java.lang.String)
4

0 回答 0