mirror of
https://github.com/TeamVanced/VancedMicroG
synced 2025-01-03 16:15:55 +01:00
Start using proguard
This commit is contained in:
parent
508babfb1b
commit
3ff5ad0e7a
@ -98,6 +98,12 @@ android {
|
|||||||
// TODO: Remove MissingTranslation once we have stable strings and proper translations.
|
// TODO: Remove MissingTranslation once we have stable strings and proper translations.
|
||||||
disable 'MissingTranslation', 'InvalidPackage'
|
disable 'MissingTranslation', 'InvalidPackage'
|
||||||
}
|
}
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled true
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (file('user.gradle').exists()) {
|
if (file('user.gradle').exists()) {
|
||||||
|
1
play-services-core/proguard-rules.pro
vendored
Symbolic link
1
play-services-core/proguard-rules.pro
vendored
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
../proguard.flags
|
@ -1,10 +1,35 @@
|
|||||||
|
# We use ProGuard for optimizations, obfuscation is for those who have sth to hide
|
||||||
|
-dontobfuscate
|
||||||
|
-optimizations !code/allocation/variable
|
||||||
|
|
||||||
|
# We're referencing stuff that is unknown to the system
|
||||||
|
-libraryjar ../unifiednlp-compat/build/classes/main
|
||||||
|
-dontwarn java.awt.**
|
||||||
|
-dontwarn javax.annotation.**
|
||||||
|
|
||||||
|
# OkIO, OkHttp
|
||||||
|
-dontwarn okio.**
|
||||||
|
-dontwarn com.squareup.okhttp.**
|
||||||
|
-dontwarn org.oscim.tiling.source.OkHttpEngine
|
||||||
|
-dontwarn org.oscim.tiling.source.OkHttpEngine$OkHttpFactory
|
||||||
|
|
||||||
# Disable ProGuard Notes, they won't help here
|
# Disable ProGuard Notes, they won't help here
|
||||||
-dontnote
|
-dontnote
|
||||||
|
|
||||||
# Keep dynamically loaded GMS classes
|
# Keep dynamically loaded GMS classes
|
||||||
-keep public class com.google.android.gms.maps.internal.CreatorImpl
|
-keep public class com.google.android.gms.maps.internal.CreatorImpl
|
||||||
-keep public class com.google.android.gms.common.security.ProviderInstallerImpl
|
-keep public class com.google.android.gms.common.security.ProviderInstallerImpl
|
||||||
|
-keep public class com.google.android.gms.plus.plusone.PlusOneButtonCreatorImpl
|
||||||
|
|
||||||
-keepclassmembers class com.google.android.gms.common.security.ProviderInstallerImpl {
|
-keepclassmembers class com.google.android.gms.common.security.ProviderInstallerImpl {
|
||||||
public *;
|
public *;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Keep library info
|
||||||
|
-keep class **.BuildConfig
|
||||||
|
-keepclassmembers class **.BuildConfig { *; }
|
||||||
|
|
||||||
|
# Keep protobuf class builders
|
||||||
|
-keep public class * extends com.squareup.wire.Message
|
||||||
|
-keep public class * extends com.squareup.wire.Message$Builder
|
||||||
|
-keepclassmembers class * extends com.squareup.wire.Message$Builder { public <init>(...); }
|
||||||
|
Loading…
Reference in New Issue
Block a user