android-support-multidex.jar在eclipse中不工作 [英] android-support-multidex.jar not working in eclipse
问题描述
这是我遵循的步骤,
1)将android-support-multidex.jar添加到构建路径中,
2)覆盖,Application类中的以下方法。因为我是自定义应用程序类的子类。
@Override
protected void attachBaseContext(Context base){
// TODO自动生成的方法存根
super.attachBaseContext(base);
MultiDex.install(this);
}
但是我无法在eclipse中实现这一点。任何解决方案?
可能的重复此处。 Alex Lipov的答案:
看起来像ADT的 ant-tasks项目不再维护(
驻留在legacy文件夹下)。所以如果你不能迁移到Gradle,
你可以编辑 DexExecTask 。您当然可以
在本地重建项目。
maven- android-plugin 确实支持多指标。新新200新200新新新新旗新新旗新新旗新新旗新新200新新旗新新旗新新旗新新旗新200新新旗新新旗新200新新旗新新200新新旗新新200新新旗新新200新新旗新新200新新旗新新200新新新200新新200新新200新新200新新200新新200新新200新新200新这个拉请求努力修复
,所以留下新新新旗新新新新旗新新旗新新旗旗新1992新新新旗新新旗新新旗旗新新旗新旗旗新新旗新旗新旗新旗新Recently I faced 65K method limitation issue in my android project. Then I started to implement multidex in that projects. When I try to add this support library in eclipse, the issue not resolved. Still it showing the 65K limitation. But when its working fine in Gradle+Android studio. How can i achieve this in eclipse? Because I don't want to switch to Android studio now.
Here is the steps I have followed,
1) Added the android-support-multidex.jar into build path, 2) overrided, the below method in Application class. Since I am subclassing custom Application class.
@Override protected void attachBaseContext(Context base) { // TODO Auto-generated method stub super.attachBaseContext(base); MultiDex.install(this); }
But I can't able to achieve this in eclipse. Any solution for this?
解决方案Possible duplicate here. Answer from Alex Lipov:
It looks like ADT's ant-tasks project is no longer maintained (it resides under 'legacy' folder). So if you can't migrate to Gradle, you can edit the DexExecTask manually. You'll have of course to rebuild the project locally..
[Edit - 10/25/2014] maven-android-plugin does support multi-dex. However, it currently has a small issue: secondary dex files placed in wrong location. This pull request strives to fix that, so stay tuned!
这篇关于android-support-multidex.jar在eclipse中不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!