APP_ABI ignored

自古美人都是妖i 提交于 2019-12-18 09:03:13

问题


I used android-ndk-r13b, I downloaded it from Android website directly (not from SDK manager) and set the path from Project Structure in the Android Studio.

It able to detect my Android.mk and Application.mk (both in my jni folder), I saw it from console log. In my Application.mk, I define this : APP_ABI:=armeabi-v7a

But from the console log, I could see that everytime it execute ndk-build, there is always APP_ABI:=mips64 as the parameter. So, there is always an error. (I guess it is because of this wrong parameter, I got error "linker command failed...", because I compiled the .a and .so for armeabi-v7a not mips64)

So, I wonder what makes my Application.mk with APP_ABI defined is ignored ? (I already link the C++ to my gradle anyway)

I tried using: arguments "APP_ABI:=armeabi-v7a" in ndkBuild{} But it said, there is no method such as arguments()

did i miss something ?


回答1:


Found it ! Add this inside defaultConfig {} in app.gradle => ndk{abiFilters 'armeabi-v7a'}



来源:https://stackoverflow.com/questions/45603295/app-abi-ignored

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!