From e1e1c20dbe3d49ca3175e5f6ed8c5e16a84b16ba Mon Sep 17 00:00:00 2001 From: arkon Date: Thu, 26 May 2022 22:33:18 -0400 Subject: [PATCH] Downgrade R8 to avoid extension issues --- .github/renovate.json | 1 + app/proguard-rules.pro | 5 +---- build.gradle.kts | 4 ++++ 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/renovate.json b/.github/renovate.json index a1eec22be2..7b8888063c 100644 --- a/.github/renovate.json +++ b/.github/renovate.json @@ -8,6 +8,7 @@ "androidx.work:work-runtime-ktx", "info.android15.nucleus:nucleus-support-v7", "info.android15.nucleus:nucleus", + "com.android.tools:r8", "com.google.guava:guava" ] } diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index b36d3f7d51..6d2edef5ec 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -2,7 +2,7 @@ # Keep common dependencies used in extensions -keep,allowoptimization class eu.kanade.tachiyomi.** { public protected *; } --keep,allowoptimization class androidx.preference.** { *; } +-keep,allowoptimization class androidx.preference.** { public protected *; } -keep,allowoptimization class kotlin.** { public protected *; } -keep,allowoptimization class kotlinx.coroutines.** { public protected *; } -keep,allowoptimization class kotlinx.serialization.** { public protected *; } @@ -14,9 +14,6 @@ -keep,allowoptimization class app.cash.quickjs.** { public protected *; } -keep,allowoptimization class uy.kohesive.injekt.** { public protected *; } -# Avoid optimizations, including access modification --keep class * { ; ; } - ##---------------Begin: proguard configuration for RxJava 1.x ---------- -dontwarn sun.misc.** diff --git a/build.gradle.kts b/build.gradle.kts index dc860796d3..1bb42db5ef 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,9 @@ buildscript { dependencies { + // Pinning to older version of R8 due to weird forced optimizations in newer versions in + // version bundled with AGP + // https://mvnrepository.com/artifact/com.android.tools/r8?repo=google + classpath("com.android.tools:r8:3.1.66") classpath(libs.android.shortcut.gradle) classpath(libs.google.services.gradle) classpath(libs.aboutLibraries.gradle)