Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Progruard and R8 being deprecated - Android Studio 3.6

I'm getting deprecated warnings in regards to Proguard as well as R8 after upgrading my Android Studio to 3.6. Does that mean we shouldn't use obfuscation in our projects or is there another equivalent option we should consider while building in release mode?

The option 'android.enableR8' is deprecated and should not be used anymore. It will be removed in a future version of the Android Gradle plugin, and will no longer allow you to disable R8. Affected Modules: etc

like image 925
Eric Avatar asked Feb 25 '20 15:02

Eric


1 Answers

Does that mean we shouldn't use obfuscation in our projects

No. You can use obfuscation and optimization tooling.

is there another equivalent option we should consider while building in release mode

If you have android.enableR8 = true in your gradle.properties, remove it as R8 it the default tooling and the android.enableR8 setting itself is deprecated, causing these deprecation warnings.

If you have android.enableR8 = false to use proguard for optimiation and obfuscation, consider migrating to R8 instead.

like image 161
laalto Avatar answered Sep 22 '22 13:09

laalto