2014-09-20 30 views
0

當我必須導出與Proguard APK時,我得到一個錯誤。我不明白什麼是實際問題。 我的錯誤控制檯是這樣的:當導出與Proguard的APK然後得到errror代碼1

[2014-09-20 10:30:44 - MyApp] Proguard returned with error code 1. See console 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.servlet.BshServlet: can't find superclass or interface javax.servlet.http.HttpServlet 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.AWTConsole: can't find superclass or interface java.awt.TextArea 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.AWTConsole: can't find superclass or interface java.awt.event.KeyListener 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.AWTConsole$1: can't find superclass or interface java.awt.event.WindowAdapter 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.AWTDemoApplet: can't find superclass or interface java.applet.Applet 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.AWTRemoteApplet: can't find superclass or interface java.applet.Applet 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.BeanShellBSFEngine: can't find superclass or interface org.apache.bsf.util.BSFEngineImpl 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.BshCanvas: can't find superclass or interface javax.swing.JComponent 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.ClassBrowser: can't find superclass or interface javax.swing.JSplitPane 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.ClassBrowser: can't find superclass or interface javax.swing.event.ListSelectionListener 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.ClassBrowser$1: can't find superclass or interface javax.swing.event.TreeSelectionListener 
[2014-09-20 10:30:44 - MyApp] Warning: bsh.util.ClassBrowser$2: can't find superclass or interface javax.swing.event.TreeSelectionListener 

請給我的解決方案。提前致謝。

+0

-keep public class * extends android.view.View { public (android.content.Context); public (android.content.Context,android.util.AttributeSet); public (android.content.Context,android.util.AttributeSet,int); public void set *(...); } – 2014-09-20 05:13:04

+0

之前只是乾淨的項目 – 2014-09-20 05:13:30

+0

@DigveshPatel添加您的行後相同的錯誤。 – dipali 2014-09-20 05:32:35

回答

1

沒有可以使這項工作的proguard配置。

Android Java是與標準Java相同的編程語言,但運行環境不同。我在您的Proguard錯誤消息中看到參考java.awtjavax.swingjavax.servlet。 Android上不存在這些類(完整package list is here),並且沒有大量的Proguard配置將添加它們。

您必須去掉Beanshell庫才能省略所有不能使用的可選位。然後在您的項目中包含精簡版,然後重試。

相關問題