2

My apk file size is 5MB

After adding the "de.mrmaffen:vlc-android-sdk:2.0.6" to gradle, apk size increase to 62MB.

How can I resolve it?

Note: I changed it to this, But it didn't work.

compile ("de.mrmaffen:vlc-android-sdk:2.0.6"){
   exclude group: 'io.card'
}
Aniruddh Parihar
  • 3,072
  • 3
  • 21
  • 39
Ali Rez
  • 73
  • 7

1 Answers1

7

VLC uses lots of native code. As a result, it has 18-30MB of native libraries per CPU architecture. While that will be compressed somewhat in the APK, a 57MB increase in APK is actually better than I would expect.

You either need to:

  • Live with it, or

  • Use splits or product flavors to indicate which subset of CPU architectures you are willing to support (the library itself supports arm64-v8a, armeabi-v7a, mips, x86, and x86_64), or

  • Do not use VLC

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491