Android NDK C++ JNI (no implementation found for native…)

后端 未结 11 1194
慢半拍i
慢半拍i 2020-11-30 02:02

I\'m trying to use the NDK with C++ and can\'t seem to get the method naming convention correct. my native method is as follows:

extern \"C\" {
JNIEXPORT voi         


        
11条回答
  •  甜味超标
    2020-11-30 02:34

    An additional reason: Use LOCAL_WHOLE_STATIC_LIBRARIES instead of LOCAL_STATIC_LIBRARIES in android.mk. This stops the library from optimizing out unused API calls because the NDK cannot detect the use of the native bindings from java code.

提交回复
热议问题