1. 程式人生 > >解決安卓中單個dex方法數超過65535的方法

解決安卓中單個dex方法數超過65535的方法

ati oid 超過 sta get ble text enabled 方法

1、百度下載 60K-methods.jar包,復制至libs文件夾中,添加到gradle中

2、在build.gradle中的defaultConfig{}下添加 multiDexEnabled true

3、 方法一、在manifest文件中,application下添加 android:name= "android.support.multidex.MultiDexApplication"

  方法二、新建Application類,在onCreate方法中,添加方法 MultiDex.install(getTargetContext()); 推薦使用attachBaseContext()方法

解決安卓中單個dex方法數超過65535的方法