Proguard causing runtime exception with Android Navigation Component

I know that Proguard and R8 should be keeping all the children of library classes but in this case, the fragment class seems to be missing. This keep rule solved my issue but technically we should not need this rule at all! -keep class * extends android.support.v4.app.Fragment{} If you are using AndroidX, then use this … Read more

Android/java: Transition / Migration from ProGuard to R8?

Proguard is developed and maintained by GuardSquare while R8 is developed and maintained by Android team which means they are two different products although R8 is compatible with Proguard. As seen from here https://www.guardsquare.com/en/blog/proguard-and-r8 Compatibility of ProGuard and R8 The good news for developers is that R8 is backward compatible with ProGuard. If you have … Read more

How to perform minification and obfuscation with the JACK compiler?

J.A.C.K. obfuscation does not appear to be supported in the latest released Gradle Plugin (v2.1.0). If you enable JACK when using the latest v2.1.0 plugin, it will tell you Jack requires Build Tools 24.0.0 or later requiring you to use the preview tools. Using android gradle v2.2.0-alpha1, Build Tools-v24rc4, Platform Tools-v24rc3, and Sdk Tools-v25.1.7rc1 I … Read more

Xamarin.Android Proguard – Unsupported class version number 52.0

You need to update the default Android SDK proguard.jar with the latest version of Proguard found here: https://sourceforge.net/projects/proguard/files/ I would recommend that you install this on the side of the default version that Android ships in android-sdk\tools\proguard. Simply rename the existing folder to something else and add the new version of proguard. This is listed … Read more

Error:Execution failed for task ‘:android:transformClassesAndResourcesWithProguardForRelease’

This bug happens when the versions of SDK, Build Tools and Gradle Plugins doesn’t match (in terms of compatibility). The solution is to verify if you are using the latest versions of them. The gradle plugins are placed in the build.gradle file of the project. Other versions are in the build.gradle file of the module. … Read more