的Android proguard的规则给出了twilio客户端SDK

问题描述:

我已经加入了Twilio客户端SDK具有以下proguard的规则的Android proguard的规则给出了twilio客户端SDK

# Twilio Client 
-keep class com.twilio.** { *; } 
# Apache HttpClient 
-dontwarn org.apache.http.** 
-keepattributes InnerClasses 

这项步骤添加我得到了下面的一组错误消息

Warning:library class android.webkit.WebView depends on program class android.net.http.SslCertificate 
Warning:library class android.webkit.WebViewClient depends on program class android.net.http.SslError 
Warning:there were 3 instances of library classes depending on program classes. 
Warning:Exception while processing task java.io.IOException: Please correct the above warnings first. 
Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForRelease'. 
> java.io.IOException: Please correct the above warnings first. 

的出错抑制错误我已经添加了这些规则集

-keep public class android.net.http.SslError 
-keep public class android.webkit.WebViewClient 

-dontwarn android.webkit.WebView 
-dontwarn android.net.http.SslError 
-dontwarn android.webkit.WebViewClient 

当我这样做时,我得到了这些设置的错误

Error:warning: Ignoring InnerClasses attribute for an anonymous inner class 
Error:(android.support.design.widget.o) that doesn't come with an 
Error:associated EnclosingMethod attribute. This class was probably produced by a 
Error:compiler that did not target the modern .class file format. The recommended 
Error:solution is to recompile the class from source, using an up-to-date compiler 

这打破了apk版本。任何形式的帮助将不胜感激。 TIA

Error:warning: Ignoring InnerClasses attribute for an anonymous inner class 
Error:(android.support.design.widget.o) that doesn't come with an 
Error:associated EnclosingMethod attribute. This class was probably produced by a 
Error:compiler that did not target the modern .class file format. The recommended 
Error:solution is to recompile the class from source, using an up-to-date compiler 

为了解决内部类的问题在你的ProGuard文件补充一点:

-keepattributes EnclosingMethod 
+0

能否请你介绍更多的解决方案吗? – silverFoxA