Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow building only split APKs #3

Closed
lberrymage opened this issue Feb 7, 2023 · 1 comment
Closed

Allow building only split APKs #3

lberrymage opened this issue Feb 7, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@lberrymage
Copy link
Member

As per the default behavior of bundletool, standalone APKs are generated when generating an APK set for an app with minSdk < 21. This is not always desirable since the publishing app store may not support such old versions of Android and so will waste disk space since split APKs are sufficient for its needs. There should be an option to override this behavior and only build split APKs even for apps with a minSdk < 21.

The easiest (and most likely best) way to override this behavior is simply to override the app's minSdk from this plugin. This also has the advantage of solving the related (albeit less severe) issue of split APKs with compressed native libraries being generated when uncompressed native libraries are supported (the issue is less severe since it doesn't often produce nearly as much wasted disk space).

Upstream issue: google/bundletool#309

@lberrymage lberrymage added the enhancement New feature or request label Feb 7, 2023
@lberrymage
Copy link
Member Author

An alternative (and perhaps a better one) to modifying the minSdk is adding options to the plugin configuration such as stripCompressedDex and stripStandalones which enable an extra step to remove the corresponding files from the generated APK set.

lberrymage added a commit that referenced this issue Jan 24, 2024
Standalone APKs are now stripped from APK sets by default. This behavior
can be overridden in the plugin's configuration.

Closes #3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Implemented
Status: Beta
Development

No branches or pull requests

1 participant