Hello,
I try to build libvlc.aar to my project but occur error when use nativeInit(). Please help me to fix this bug! Thanks!
My code is:
public void init(Context context) throws LibVlcException {
//Log.v(TAG, "Initializing LibVLC");
mDebugLogBuffer = new StringBuffer();
if (!mIsInitialized) {
if (!LibVlcUtil.hasCompatibleCPU(context)) {
//Log.e(TAG, LibVlcUtil.getErrorMsg());
throw new LibVlcException();
}
nativeInit();
mMediaList = mPrimaryList = new MediaList(this);
setEventHandler(EventHandler.getInstance());
mIsInitialized = true;
}
}
Below is log:
java.lang.UnsatisfiedLinkError: No implementation found for void org.videolan.libvlc.LibVLC.nativeInit() (tried Java_org_videolan_libvlc_LibVLC_nativeInit and Java_org_videolan_libvlc_LibVLC_nativeInit__)
at org.videolan.libvlc.LibVLC.nativeInit(Native Method)
at org.videolan.libvlc.LibVLC.init(LibVLC.java:450)
at org.videolan.vlc.Util.getLibVlcInstance(Util.java:131)
at org.videolan.vlc.gui.MainActivity.onCreate(MainActivity.java:183)
at android.app.Activity.performCreate(Activity.java:5975)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2269)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2378)
at android.app.ActivityThread.access$800(ActivityThread.java:147)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1281)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5255)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:652)
at Android.MODEL(P01Y)
at Android.VERSION(5.0.2)
at Android.FINGERPRINT(asus/WW_P01Y/P01Y:5.0.2/LRX22G/WW_ZenPad-12.26.4.57-20160419:user/release-keys)