Gcanvas-For-Apache-weex icon indicating copy to clipboard operation
Gcanvas-For-Apache-weex copied to clipboard

报错,找不到native方法

Open 1903514970 opened this issue 7 years ago • 1 comments

集成需要so包吗?现在没有so包报错。

java.lang.UnsatisfiedLinkError: Native method not found: com.taobao.gcanvas.GCanvasJNI.newCanvas:(Ljava/lang/String;I)V at com.taobao.gcanvas.GCanvasJNI.newCanvas(Native Method) at com.taobao.gcanvas.GCanvasRenderer.(GCanvasRenderer.java:91) at com.taobao.gcanvas.GCanvasView.(GCanvasView.java:64) at com.cuju.weex.component.view.gcanvas.WXGCanvasGLSurfaceView.(WXGCanvasGLSurfaceView.java:21) at com.cuju.weex.component.view.gcanvas.WXGcanvasComponent.initComponentHostView(WXGcanvasComponent.java:53) at com.cuju.weex.component.view.gcanvas.WXGcanvasComponent.initComponentHostView(WXGcanvasComponent.java:17) at com.taobao.weex.ui.component.WXComponent.createViewImpl(WXComponent.java:875) at com.taobao.weex.ui.component.WXComponent.createView(WXComponent.java:869) at com.taobao.weex.ui.component.WXVContainer.createChildViewAt(WXVContainer.java:255) at com.taobao.weex.dom.action.AddElementAction.executeRender(AddElementAction.java:102) at com.taobao.weex.dom.RenderActionTask.execute(RenderActionTask.java:39) at com.taobao.weex.ui.WXRenderManager$1.run(WXRenderManager.java:99) at com.taobao.weex.common.WXThread$SafeRunnable.run(WXThread.java:49) at android.os.Handler.handleCallback(Handler.java:808) at android.os.Handler.dispatchMessage(Handler.java:103) at android.os.Looper.loop(Looper.java:193) at android.app.ActivityThread.main(ActivityThread.java:5292) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:824) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:640) at dalvik.system.NativeStart.main(Native Method)

1903514970 avatar May 03 '17 06:05 1903514970

hi 建议你切到dev分支 https://github.com/weex-plugins/weex-plugin-gcanvas/tree/dev 用android studio 直接打开playground/android目录, 应该直接就可以编译通过并运行成功

lycool avatar May 03 '17 07:05 lycool