【发布时间】:2019-03-16 02:16:21
【问题描述】:
我想构建 APK 文件,但使用 Proguard 时出现此错误:
找不到 [com/google/android/gms/internal/zzol](具有 2 个已知超类)和 [com/google/android/gms/internal/zzoj](具有 2 个已知超类)
这是我的毕业典礼:
dependencies {
implementation 'com.android.support:appcompat-v7:27.0.2'
implementation 'com.android.support:recyclerview-v7:27.0.2'
implementation 'com.android.support:cardview-v7:27.0.2'
implementation 'com.android.support:design:27.0.2'
implementation ('cn.trinea.android.view.autoscrollviewpager:android-auto-scroll-view-pager:1.1.2') {
exclude module: 'support-v4'
}
implementation 'com.github.bumptech.glide:glide:3.7.0'
implementation 'com.github.shell-software:fab:1.1.2'
implementation 'com.alirezaafkar:sundatepicker:2.0.8'
implementation 'me.dm7.barcodescanner:zxing:1.9'
implementation 'com.google.android.gms:play-services-maps:16.0.0'
implementation 'com.google.android.gms:play-services-gcm:16.0.0'
implementation 'com.google.android.gms:play-services-location:16.0.0'
implementation 'com.alirezaafkar:sundatepicker:2.0.8'
implementation 'me.cheshmak:analytics:2.0.+'
}
这是我尝试解决错误的proguard,但它不起作用:
-keep public class com.google.android.gms.* { public *; }
-keep class com.google.android.gms.* { *; }
-keep class com.google.* { *; }
-dontwarn com.google.**
我该如何解决这个问题?
【问题讨论】:
-
您有解决方案吗?提前致谢
-
@SandeepReddyM 是的,它来自我的一个库,我删除它并重建项目,问题就消失了
标签: android android-studio google-play-services android-proguard