diff --git a/plugins/src/main/kotlin/Versions.kt b/plugins/src/main/kotlin/Versions.kt index c663310f1f..76a66dd519 100644 --- a/plugins/src/main/kotlin/Versions.kt +++ b/plugins/src/main/kotlin/Versions.kt @@ -63,6 +63,7 @@ object Versions { val versionName = "$versionMajor.$versionMinor.$versionPatch" const val compileSdk = 34 const val targetSdk = 33 + // When updating the `minSdk`, make sure to update the value of `minSdkVersion` in the file `tools/release/release.sh` const val minSdk = 24 val javaCompileVersion = JavaVersion.VERSION_17 val javaLanguageVersion: JavaLanguageVersion = JavaLanguageVersion.of(11) diff --git a/tools/release/release.sh b/tools/release/release.sh index 2e7999fd21..d51a702388 100755 --- a/tools/release/release.sh +++ b/tools/release/release.sh @@ -73,8 +73,8 @@ if [ ${envError} == 1 ]; then exit 1 fi -minSdkVersion=23 -buildToolsVersion="32.0.0" +minSdkVersion=24 +buildToolsVersion="35.0.0" buildToolsPath="${androidHome}/build-tools/${buildToolsVersion}" if [[ ! -d ${buildToolsPath} ]]; then @@ -230,6 +230,17 @@ printf "Unzipping the F-Droid artifact...\n" fdroidTargetPath="${targetPath}/fdroid" unzip "${targetPath}"/elementx-app-fdroid-apks-unsigned.zip -d "${fdroidTargetPath}" +printf "\n================================================================================\n" +printf "Patching the FDroid APKs using inplace-fix.py...\n" + +inplaceFixScript="./tmp/inplace-fix.py" +curl -s https://raw.githubusercontent.com/obfusk/reproducible-apk-tools/master/inplace-fix.py --output "${inplaceFixScript}" + +python3 "${inplaceFixScript}" --page-size 16 fix-pg-map-id "${fdroidTargetPath}"/app-fdroid-arm64-v8a-release.apk '0000000' +python3 "${inplaceFixScript}" --page-size 16 fix-pg-map-id "${fdroidTargetPath}"/app-fdroid-armeabi-v7a-release.apk '0000000' +python3 "${inplaceFixScript}" --page-size 16 fix-pg-map-id "${fdroidTargetPath}"/app-fdroid-x86-release.apk '0000000' +python3 "${inplaceFixScript}" --page-size 16 fix-pg-map-id "${fdroidTargetPath}"/app-fdroid-x86_64-release.apk '0000000' + printf "\n================================================================================\n" printf "Signing the FDroid APKs...\n"