Android的错误"转换到的Dalvik格式失败,错误2英寸;? [英] Android Error "Conversion to Dalvik format failed with error 2"?

查看:235
本文介绍了Android的错误"转换到的Dalvik格式失败,错误2英寸;?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用乱舞的SDK在我的应用程序,添加此乱舞JAR文件它的正常工作与出任何错误了。我得到这个错误将乱舞的jar文件中libs文件夹后,当我编译应用程序在Eclipse中。

I am using flurry sdk in my application, before adding this flurry jar file it's working fine with out any errors. after adding flurry jar file in libs folder i am getting this error when i am compiling application in Eclipse.

trouble writing output: Too many methods: 70205; max is 65536. By package:
  5 android.accessibilityservice
  1 android.animation
  2 android.annotation
315 android.app
136 android.content
 28 android.content.pm
 47 android.content.res
 35 android.database
 14 android.database.sqlite
  8 android.gesture
113 android.graphics
 44 android.graphics.drawable
  1 android.graphics.drawable.shapes
 11 android.location
 27 android.media
 40 android.net
  1 android.net.http
  1 android.net.wifi
 96 android.os

[2013-03-04 16:42:13 - myapp] Conversion to Dalvik format failed with error 2

我的想法如何解决错误1 ,但这对我来说是无法解决的新的错误。我搜索了很多我以前不得到这个任何解决方案。

I have idea about how to solve error 1 but this is the new error for me unable to solve. i searched a lot did't get any solution for this.

当我删除此jar文件它的正常工作。如果它在库无法运行应用程序。 为什么我收到这个错误?什么是sollution这个..

when i remove this jar file it's working fine. if it has in libs not able to run the application. Why i am getting this error.? what is the sollution for this..

推荐答案

由于误差麻烦写输出:有太多的方法:70205;最大为65536 的sollution为本是由约10%,以减少你的方法计数。

Since the error is trouble writing output: Too many methods: 70205; max is 65536, "the sollution for this" is to reduce your method count by about 10%.

通常这是有太多的罐子方法太多惹的祸,但它肯定是可以想象的,你写的方法几万吧。

Usually this is the fault of having too many JARs with too many methods, though it is certainly conceivable that you wrote tens of thousands of methods yourself.

试着找一些JAR,你并不需要将其取出。例如,您可以使用ProGuard的到你的应用内报告死亡code - 也许有一些库,该库通常需要的依赖JAR,但你碰巧使用该库的方式是没有必要的。

Try to find some JAR that you do not need and remove it. For example, you can use ProGuard to report the dead code within your app -- perhaps there is a dependent JAR of some library that the library ordinarily needs, but the way you happen to use the library is not needed.

ProGuard的本身也可以用来只是从你的应用程序中删除那个死code,没有一切正常混淆的东西。然而,这是不正常的构建过程的一部分,所以你必须以某种方式煮了一个Ant脚本这一点。

ProGuard itself can also be used just to remove that dead code from your app, without all the normal obfuscation stuff. However, this is not part of the normal build process, so you'd have to somehow cook up an Ant script for this.

这篇关于Android的错误"转换到的Dalvik格式失败,错误2英寸;?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆