我正在构建一个库项目,其中我正在使用 3rd 方 jar 文件。
通常,当我使用该库作为对 TestApp 的依赖项时,所有事情都可以正常工作。附上它的截图:
但是,当我从TestSDK
库项目中导出 jar 并将其添加到的构建路径中时TestApp
,如下所示:
我VerifyError
在设备上部署应用程序时得到。以下是它的日志:
12-30 18:10:55.778: W/dalvikvm(7316): VFY: unable to find class referenced in signature (Lcom/aerserv/sdk/ASAdView;)
12-30 18:10:55.788: W/dalvikvm(7316): VFY: Ljava/lang/Object; is not instance of Landroid/view/View;
12-30 18:10:55.788: W/dalvikvm(7316): VFY: bad arg 1 (into Landroid/view/View;)
12-30 18:10:55.788: W/dalvikvm(7316): VFY: rejecting call to Landroid/view/ViewGroup;.removeView (Landroid/view/View;)V
12-30 18:10:55.788: W/dalvikvm(7316): VFY: rejecting opcode 0x6e at 0x0011
12-30 18:10:55.788: W/dalvikvm(7316): VFY: rejected Lcom/anupam/sdk/activities/AdsActivity;.initAerservAd ()V
12-30 18:10:55.788: W/dalvikvm(7316): Verifier rejected class Lcom/anupam/sdk/activities/AdsActivity;
12-30 18:10:55.788: W/dalvikvm(7316): Class init failed in newInstance call (Lcom/anupam/sdk/activities/AdsActivity;)
12-30 18:10:55.788: D/AndroidRuntime(7316): Shutting down VM
12-30 18:10:55.788: W/dalvikvm(7316): threadid=1: thread exiting with uncaught exception (group=0x41596ba8)
12-30 18:10:55.788: E/AndroidRuntime(7316): FATAL EXCEPTION: main
12-30 18:10:55.788: E/AndroidRuntime(7316): Process: com.anupam.testsdk, PID: 7316
12-30 18:10:55.788: E/AndroidRuntime(7316): java.lang.VerifyError: com/anupam/sdk/activities/AdsActivity
正确的方法应该是什么?我在这里错过了什么吗。任何形式的帮助或指导将不胜感激。