Shared library not loaded on Android
<p>I would like to use <a href="https://sourceforge.net/projects/mediainfo/" rel="nofollow noreferrer">MediaInfo</a> library in my application. It is not easy to compile it for Android but I found an already compiled binary version <a href="https://github.com/OLEG4120/MediaInfoCLI-android" rel="nofollow noreferrer">here</a>.</p>
<p>I use QtCreator to develop my application and build the installation APK. On Windows everything runs fine. But if I try it on Android, I first get this error when starting the application:</p>
<blockquote>
<p>D/dalvikvm( 3296): Trying to load lib/data/app-lib/org.qtproject.muzika-2/libmediainfo.so 0xb3d087b0</p>
<p>E/linker ( 3296): &quot;libmediainfo.so&quot;: ignoring 2-entry DT_PREINIT_ARRAY in shared library!</p>
<p>D/dalvikvm( 3296): Added shared lib/data/app-lib/org.qtproject.muzika-2/libmediainfo.so 0xb3d087b0</p>
<p>D/dalvikvm( 3296): No JNI_OnLoad found in /data/app-lib/org.qtproject.muzika-2/libmediainfo.so 0xb3d087b0, skipping init</p>
</blockquote>
<p>But at least it seems the library was found an loaded. But if I try to actually use it, I get always this output:</p>
<blockquote>
<p>D/libMuzika.so( 3296): (null):0 ((null)): &quot;Unable to load libmediainfo.so&quot;</p>
</blockquote>
<p>I do believe the error message comes from the <a href="https://sourceforge.net/p/mediainfo/code/HEAD/tree/MediaInfoLib/trunk/Source/MediaInfoDLL/MediaInfoDLL.h#l544" rel="nofollow noreferrer">header file of this library</a>. For some reason the library is not loaded. But I'm not able to figure out why.</p>
<p>How can I find out what is the problem?</p>