Our project is facing issues of this kind: http://issuetracker.unity3d.com/issues/android-slash-il2cpp-shared-library-on-il2cpp-built-apk-does-not-load-and-causes-dllnotfoundexception
However, while not having access to the source code of the 3rd-party lib which we wish to use, we do have a static version of it.
It appears that .so files inside Plugin/Android are magically copied to the appropriate place in the final apk, but dropping a .a file there does not mean it is included in the link command generating il2cpp.so.
Is there, by any chance, a way to let Unity know about static libraries to be linked against?
Answer by Yury-Habets
Nov 27, 2015 at 11:03 AM
We don't support static libraries, at least at the moment.
Your bug with "dll not found" was fixed, and is planned to get into 5.2 patch release as well.
With the latest Unity 5.4 where il2cpp android goes official, does this impediment remains? I mean, unable to link to a static lib?
No static libs are not supported for Android IL2CPP at the moment.
Why would you want to use it?
Anyway - if you have a static lib that you want to make use, it's easy to link it into a .so and use it as a native plugin.
Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.
The best place to ask and answer questions about development with Unity.
To help users navigate the site we have posted a site navigation guide.
If you are a new user to Unity Answers, check out our FAQ for more information.
Make sure to check out our Knowledge Base for commonly asked Unity questions.
If you are a moderator, see our Moderator Guidelines page.
We are making improvements to UA, see the list of changes.
Answers and Comments
6 People are following this question.
Which C# libraries are compatible with Unity Android or iOS
Which files in a Unity Android build are specific to the actual game
Native plugin JNI_OnLoad/UnitySetGraphicsDevice not called when using IL2CPP on Android
Gradle file for Unity
Android plugin conflict: Unable to convert classes into dex format