2014-10-02 53 views
3

我試圖用戶谷歌分析,這導致我更新adt和播放服務庫,以獲得最新版本,包含analytics4。這之後,我會有點建立ptoject和我更新sdk和播放服務後,建設eclipse項目的錯誤[無法執行dex:方法ID不在]

[2014-10-03 01:48:47 - Dex Loader] Unable to execute dex: method ID not in [0, 0xffff]: 65536 
[2014-10-03 01:48:47 - chatter] Conversion to Dalvik format failed: Unable to execute dex: method ID not in [0, 0xffff]: 65536 


[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$2) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$3) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$4) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$5) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.LogFactory$6) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.impl.LogFactoryImpl$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.impl.LogFactoryImpl$2) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.impl.LogFactoryImpl$3) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.impl.SimpleLog$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:34 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(org.apache.commons.logging.impl.WeakHashtable$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:39 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.StaxErrorReporter$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:39 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.XMLReaderImpl$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:40 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.xerces.util.SecuritySupport12$1) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:40 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.xerces.util.SecuritySupport12$2) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:40 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.xerces.util.SecuritySupport12$3) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 
[2014-10-03 01:48:40 - chatter] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class 
(com.amazonaws.javax.xml.stream.xerces.util.SecuritySupport12$4) that doesn't come with an 
associated EnclosingMethod attribute. This class was probably produced by a 
compiler that did not target the modern .class file format. The recommended 
solution is to recompile the class from source, using an up-to-date compiler 
and without specifying any "-target" type options. The consequence of ignoring 
this warning is that reflective operations on this class will incorrectly 
indicate that it is *not* an inner class. 

回答

4

正確的答案被描述here

在快速: 1-使用android studio 2-在Android工作室中啓用多重dex

0
[2014-10-03 01:48:47 - Dex Loader] Unable to execute dex: method ID not in [0, 0xffff]: 65536 
[2014-10-03 01:48:47 - chatter] Conversion to Dalvik format failed: Unable to execute dex: method ID not in [0, 0xffff]: 65536 

您已經達到了64K DEX方法參考限值以下錯誤和警告。總之,你的應用程序太大了。您需要刪除一些庫,或嘗試僅在創建調試版本時應用ProGuard進行收縮,或者考慮將應用拆分爲多個DEX文件。

例如,如果您使用Play Services SDK的唯一原因是用於分析,您可能會考慮使用具有較小客戶端庫的不同分析服務,因爲Play Services SDK非常龐大。

參見:

+0

我會考慮自定義類加載方法。我們可以在eclipse中做到這一點嗎?以某種方式在eclipse運行選項中集成ant? – MSaudi 2014-10-03 00:40:56

+0

@MSaudi:我知道拆分DEX /自定義類加載的東西已經完成與Ant(我假定Eclipse)。儘管如此,我沒有任何食譜方便。 – CommonsWare 2014-10-03 10:22:36

+0

我希望輸出結果會顯示我有多少種方法超過64K,以便我可以判斷它是否值得重構。 – 2015-04-01 21:38:17

相關問題