From 8ccd2864fe03a97a6cf1049ddd55bdced7233271 Mon Sep 17 00:00:00 2001 From: Greyson Parrelli Date: Tue, 6 Jan 2026 11:59:18 -0500 Subject: [PATCH] Use legacy packaging for website builds to reduce download size. --- app/build.gradle.kts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 7f177df91b..dce8e2d0e5 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -459,6 +459,12 @@ android { variant.packaging.jniLibs.excludes.add("**/libsignal_jni_testing.so") } + // Starting with minSdk 23, Android leaves native libraries uncompressed, which is fine for the Play Store, but not for our self-distributed APKs. + // This reverts it to the legacy behavior, compressing the native libraries, and drastically reducing the APK file size. + if (variant.name.contains("website", ignoreCase = true)) { + variant.packaging.jniLibs.useLegacyPackaging.set(true) + } + // Version overrides if (variant.name.contains("nightly", ignoreCase = true)) { var tag = getNightlyTagForCurrentCommit()