Execution failed for task ':app:compileA001DebugNdk'.
> Error: Your project contains C++ files but it is not using a supported native build system.
Consider using CMake or ndk-build integration. For more information, go to:
https://d.android.com/r/studio-ui/add-native-code.html
Alternatively, you can use the experimental plugin:
https://developer.android.com/r/tools/experimental-plugin.html
那个Module中含有jni的代码,就加上,注意Android.mk的配置,以及入口的配置
ndkBuild {
path 'src/main/jni/Android.mk'
}
}
ndk {
moduleName "encry" //设置库(so)文件名称
ldLibs "log"
abiFilters "armeabi"
cFlags "****"
}