How do I add an Andrioid NDK-built shared library to my APK without using NDK?

拟墨画扇 提交于 2019-11-30 09:02:11

问题


Pretty much exact duplicate of Add a native lib to an APK. Since there was no answer I decided to ask again.

I have an Android project. I have an .so library built with android NDK. And I want to use this .so in my project, preferrably - without using NDK.

So, how do I tell Eclipse (or Android tools) that I need certain .so to be built into my APK?


回答1:


It's actually easier than I expected. All I had to do is place the .so in libs/armeabi-v7a - Eclipse saw it and integrated into APK.

However, I've made this project by copying from another Eclipse project, which was actually building this .so from source. So, I think there were some settings that I would otherwise need to set. Feel free to add corrections or edit my answer.



来源:https://stackoverflow.com/questions/8295728/how-do-i-add-an-andrioid-ndk-built-shared-library-to-my-apk-without-using-ndk

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