how to limit the first dex size while building android app by using multi-dex

443 Views Asked by At

First,I face this problem:

Conversion to Dalvik format failed:Unable toexecute dex:
method ID not in [0, 0xffff]: 65536

so,I try to division the dex provided by Google.refer Building Apps with Over 65K Methods

And I unPack the apk,it really contains two dex file and the first dex still too large,cause the apk cannot be installed in android 2.3 by cmd.

log:Failure [INSTALL_FAILED_DEXOPT]
android 2.3 linearalloc about 5M.

How to do it so that the app can install in android 2.3.

1

There are 1 best solutions below

1
On

This is the limitation. You cannot run mutidex app on device with api older than 14. The full list of limitaions is here.