生成Proguarded签名的APK问题?

问题描述 投票:2回答:1

我写了一个播放加密视频的应用程序。它运行正常但是当我想要预测apk时,会出现以下警告:

Information:Gradle tasks [:app:assembleRelease]
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.APKExpansionSupport
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile$ZipEntryRO
Warning:fr.maxcom.http.FileDataSource: can't find referenced class jcifs.smb.SmbFile
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile$ZipEntryRO
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.APKExpansionSupport
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile$ZipEntryRO
Warning:fr.maxcom.http.FileDataSource: can't find referenced class jcifs.smb.SmbFile
Warning:fr.maxcom.http.FileDataSource: can't find referenced class com.android.vending.expansion.zipfile.ZipResourceFile$ZipEntryRO
Warning:fr.maxcom.http.FileDataSource: can't find referenced class jcifs.smb.SmbFile
Warning:fr.maxcom.http.WifiSingleHttpServer: can't find referenced class com.google.android.gms.cast.CastDevice
Warning:there were 25 unresolved references to classes or interfaces.
Warning:Exception while processing task java.io.IOException: Please correct the above warnings first.
Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForRelease'.
> Job failed, see logs for details
Information:BUILD FAILED
Information:Total time: 9.897 secs
Information:1 error
Information:14 warnings
Information:See complete output in console

有什么建议?

android video encryption video-streaming proguard
1个回答
1
投票

将此行添加到proguard-rules文件解决了问题:

-dontwarn com.android.vending.expansion.zipfile.**, jcifs.smb.SmbFile, jcifs.http.*, com.google.android.gms.cast.CastDevice
© www.soinside.com 2019 - 2024. All rights reserved.