Skip to content

Commit def462a

Browse files
authored
Update README.md
1 parent 3823edd commit def462a

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

README.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,28 @@
33

44
### 接入步骤
55

6-
1. build.gradle配置
6+
1. build.gradle配置,不再需要引用官方的MultiDex库
77
```
8+
allprojects {
9+
repositories {
10+
...
11+
maven { url 'https://jitpack.io' }
12+
}
13+
}
814
15+
dependencies {
16+
implementation 'com.github.zhuozp:ComPactMultiDex:v1.0.0'
17+
}
18+
19+
defaultConfig {
20+
// 加入multiDexEnabled允许多dex打包
21+
multiDexEnabled true
22+
multiDexKeepFile file('maindexlist.txt')
23+
}
924
```
1025

11-
2. 查看路径下buid/intermediates/legacy_multidex_main_dex_list/release/mainDexList.txt, 若没有ComPactMultiDex相关的类,则加入下面的类,主要是为了确保主dex有包含到
26+
2. 创建mianDexList.txt文件(同工程build.gradle同目录),查看路径下buid/intermediates/legacy_multidex_main_dex_list/release/mainDexList.txt, 若没有ComPactMultiDex相关的类,则加入下面的类到创建的mianDexList.txt文件中,主要是为了确保主dex有包含到
27+
1228
```
1329
com/gibbon/compactmultidex/ConcurrentMultiDexExtractor$ExtractCallable.class
1430
com/gibbon/compactmultidex/ConcurrentMultiDexExtractor$ZipEntryGroup.class

0 commit comments

Comments
 (0)