用mm编译APK时大量can't find referenced method的问题的解决

来源:互联网 发布:键盘反应速度调节软件 编辑:程序博客网 时间:2024/06/10 04:51

今天在源码里面编译APK的时候,遇到一个莫名其妙的错误,中断了调试,很是恼火,百度google查了很久没结果,打印如下:

[plain] view plain copy
  1. Warning: antlr.debug.misc.ASTFrame: can't find superclass or interface javax.swing.JFrame  
  2. Warning: antlr.debug.misc.ASTFrame$1: can't find superclass or interface java.awt.event.WindowAdapter  
  3. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find superclass or interface javax.swing.event.TreeSelectionListener  
  4. Warning: antlr.debug.misc.JTreeASTModel: can't find superclass or interface javax.swing.tree.TreeModel  
  5. Warning: antlr.debug.misc.JTreeASTPanel: can't find superclass or interface javax.swing.JPanel  
  6. Warning: org.apache.tools.ant.Main: can't find superclass or interface org.apache.tools.ant.launch.AntMain  
  7. Warning: antlr.debug.misc.ASTFrame: can't find referenced class javax.swing.JFrame  
  8. Warning: antlr.debug.misc.ASTFrame: can't find referenced method 'java.awt.Container getContentPane()' in program class antlr.debug.misc.ASTFrame  
  9. Warning: antlr.debug.misc.ASTFrame: can't find referenced class java.awt.Container  
  10. Warning: antlr.debug.misc.ASTFrame: can't find referenced method 'void addWindowListener(java.awt.event.WindowListener)' in program class antlr.debug.misc.ASTFrame  
  11. Warning: antlr.debug.misc.ASTFrame: can't find referenced method 'void setSize(int,int)' in program class antlr.debug.misc.ASTFrame  
  12. Warning: antlr.debug.misc.ASTFrame: can't find referenced method 'void setVisible(boolean)' in program class antlr.debug.misc.ASTFrame  
  13. Warning: antlr.debug.misc.ASTFrame: can't find referenced class javax.swing.JFrame  
  14. Warning: antlr.debug.misc.ASTFrame: can't find referenced class java.awt.Container  
  15. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.event.WindowAdapter  
  16. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.event.WindowEvent  
  17. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.Frame  
  18. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.Frame  
  19. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.Frame  
  20. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.event.WindowAdapter  
  21. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.event.WindowEvent  
  22. Warning: antlr.debug.misc.ASTFrame$1: can't find referenced class java.awt.event.WindowEvent  
  23. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.event.TreeSelectionEvent  
  24. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.tree.TreePath  
  25. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.tree.TreePath  
  26. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.event.TreeSelectionListener  
  27. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.event.TreeSelectionEvent  
  28. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.tree.TreePath  
  29. Warning: antlr.debug.misc.ASTFrame$MyTreeSelectionListener: can't find referenced class javax.swing.event.TreeSelectionEvent  
  30. Warning: antlr.debug.misc.JTreeASTModel: can't find referenced class javax.swing.tree.TreeModel  
  31. Warning: antlr.debug.misc.JTreeASTModel: can't find referenced class javax.swing.event.TreeModelListener  
  32. Warning: antlr.debug.misc.JTreeASTModel: can't find referenced class javax.swing.event.TreeModelListener  
  33. Warning: antlr.debug.misc.JTreeASTModel: can't find referenced class javax.swing.tree.TreePath  
  34. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JPanel  
  35. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class java.awt.BorderLayout  
  36. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class java.awt.BorderLayout  
  37. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced method 'void setLayout(java.awt.LayoutManager)' in program class antlr.debug.misc.JTreeASTPanel  
  38. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JTree  
  39. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JTree  
  40. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JTree  
  41. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JTree  
  42. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JScrollPane  
  43. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JScrollPane  
  44. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JScrollPane  
  45. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JViewport  
  46. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced method 'void add(java.awt.Component,java.lang.Object)' in program class antlr.debug.misc.JTreeASTPanel  
  47. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JPanel  
  48. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JViewport  
  49. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.JTree  
  50. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.tree.TreeModel  
  51. Warning: antlr.debug.misc.JTreeASTPanel: can't find referenced class javax.swing.event.TreeSelectionListener  
  52. Warning: info.monitorenter.cpdetector.TestCodepageProcessor: can't find referenced class org.junit.Test  
  53. Warning: info.monitorenter.cpdetector.TestCodepageProcessor: can't find referenced class org.junit.Test  
  54. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Assert  
  55. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Assert  
  56. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Assert  
  57. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  58. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  59. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  60. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  61. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  62. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  63. Warning: info.monitorenter.cpdetector.io.ByteOrderMarkDetectorTest: can't find referenced class org.junit.Test  
  64. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Assert  
  65. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Assert  
  66. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Assert  
  67. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Assert  
  68. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Assert  
  69. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Before  
  70. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.After  
  71. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Test  
  72. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Test  
  73. Warning: info.monitorenter.cpdetector.io.CodePageDetectorProxyTest: can't find referenced class org.junit.Test  
  74. Warning: org.apache.tools.ant.AntClassLoader: can't find referenced class org.apache.tools.ant.launch.Locator  
  75. Warning: org.apache.tools.ant.AntClassLoader: can't find referenced class org.apache.tools.ant.launch.Locator  
  76. Warning: org.apache.tools.ant.ComponentHelper: can't find referenced class org.apache.tools.ant.launch.Launcher  
  77. Warning: org.apache.tools.ant.ComponentHelper: can't find referenced class org.apache.tools.ant.launch.Launcher  
  78. Warning: org.apache.tools.ant.Diagnostics: can't find referenced class org.apache.tools.ant.launch.Launcher  
  79. Warning: org.apache.tools.ant.Diagnostics: can't find referenced class org.apache.tools.ant.launch.Launcher  
  80. Warning: org.apache.tools.ant.Main: can't find referenced class org.apache.tools.ant.launch.AntMain  
  81. Warning: org.apache.tools.ant.Project: can't find referenced class org.apache.tools.ant.launch.Locator  
  82. Warning: org.apache.tools.ant.Project: can't find referenced class org.apache.tools.ant.launch.Locator  
  83. Warning: org.apache.tools.ant.helper.ProjectHelper2: can't find referenced class org.apache.tools.ant.launch.Locator  
  84. Warning: org.apache.tools.ant.helper.ProjectHelper2: can't find referenced class org.apache.tools.ant.launch.Locator  
  85. Warning: org.apache.tools.ant.taskdefs.ManifestClassPath: can't find referenced class org.apache.tools.ant.launch.Locator  
  86. Warning: org.apache.tools.ant.taskdefs.ManifestClassPath: can't find referenced class org.apache.tools.ant.launch.Locator  
  87. Warning: org.apache.tools.ant.taskdefs.Rmic: can't find referenced class java.rmi.Remote  
  88. Warning: org.apache.tools.ant.taskdefs.optional.javah.SunJavah: can't find referenced class org.apache.tools.ant.launch.Locator  
  89. Warning: org.apache.tools.ant.taskdefs.optional.javah.SunJavah: can't find referenced class org.apache.tools.ant.launch.Locator  
  90. Warning: org.apache.tools.ant.util.FileUtils: can't find referenced class org.apache.tools.ant.launch.Locator  
  91. Warning: org.apache.tools.ant.util.FileUtils: can't find referenced class org.apache.tools.ant.launch.Locator  
  92. Warning: org.apache.tools.ant.util.LoaderUtils: can't find referenced class org.apache.tools.ant.launch.Locator  
  93. Warning: org.apache.tools.ant.util.LoaderUtils: can't find referenced class org.apache.tools.ant.launch.Locator  
  94. Warning: org.apache.tools.ant.util.LoaderUtils: can't find referenced class org.apache.tools.ant.launch.Locator  
  95. Warning: org.apache.tools.ant.util.ProcessUtil: can't find referenced class java.lang.management.ManagementFactory  
  96. Warning: org.apache.tools.ant.util.ProcessUtil: can't find referenced class java.lang.management.RuntimeMXBean  
  97. Warning: org.apache.tools.ant.util.ProcessUtil: can't find referenced class java.lang.management.ManagementFactory  
  98. Warning: org.apache.tools.ant.util.ProcessUtil: can't find referenced class java.lang.management.RuntimeMXBean  
  99. Warning: there were 92 unresolved references to classes or interfaces.  
  100.          You may need to add missing library jars or update their versions.  
  101.          If your code works fine without the missing classes, you can suppress  
  102.          the warnings with '-dontwarn' options.  
  103.          (http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedclass)  
  104. Warning: there were 6 unresolved references to program class members.  
  105.          Your input classes appear to be inconsistent.  
  106.          You may need to recompile the code.  
  107.          (http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedprogramclassmember)  
  108. Error: Please correct the above warnings first.  

最后还是得靠自己,解决方法是在Android.mk中添加下面这一行:

LOCAL_PROGUARD_ENABLED := disabled

编译通过!


妹的,不做代码混淆就通过了,默认是要做混淆的,大量的报错。

0 0
原创粉丝点击