方法数超过64K异常

2018-04-02  本文已影响0人  Wang_Mr

Cannot merge new index 66221 into a non-jumbo instruction!

解决办法:添加支持库

compile 'com.android.support:multidex:1.0.3'

然后自定义的Application添加

    @Override
    protected void attachBaseContext(Context base) {
        super.attachBaseContext(base);
        MultiDex.install(this);
    }

在Android的模块gradle文件的defaultConfig默认配置里面增加:

multiDexEnabled true
上一篇 下一篇

猜你喜欢

热点阅读