新建项目时提示:proguard.cfg 系统找不到指定的文件<wbr>如图:</wbr>

<wbr></wbr>

proguard.cfg 系统找不到指定的文件

<wbr></wbr>

解决方法:

方法一:在<wbr>\android-sdk-windows\tools\lib\目录下新建proguard.cfg文件</wbr>

内容如下:

-optimizationpasses 5
-dontusemixedcaseclassnam<wbr>es<br> -dontskipnonpubliclibrary<wbr>classes<br> -dontpreverify<br> -verbose<br> -optimizations !code/simplification/arithmetic,!field/*,!class/merging/*<br> -keep public class * extends android.app.Activity<br> -keep public class * extends android.app.Application<br> -keep public class * extends android.app.Service<br> -keep public class * extends android.content.BroadcastReceiver<br> -keep public class * extends android.content.ContentProvider<br> -keep public class com.android.vending.licensing.ILicensingService<br> -keepclasseswithmembernam<wbr>es class * {<br> native ;<br> }<br> -keepclasseswithmembernam<wbr>es class * {<br> public (android.content.Context, android.util.AttributeSet);<br> }<br> -keepclasseswithmembernam<wbr>es class * {<br> public (android.content.Context, android.util.AttributeSet, int);<br> }<br> -keepclassmembers enum * {<br> public static **[] values();<br> public static ** valueOf(java.lang.String);<br> }<br> -keep class * implements android.os.Parcelable {<br> public static final android.os.Parcelable$Creator *;<br> }</wbr></wbr></wbr></wbr></wbr>

<wbr></wbr>

方法二:通过Android SDK and AVD Manager更新SDK。

相关文章:

  • 2021-10-29
  • 2022-01-22
  • 2021-10-02
  • 2021-05-23
  • 2022-12-23
  • 2021-11-16
  • 2021-10-12
猜你喜欢
  • 2021-08-07
  • 2022-12-23
  • 2022-01-01
  • 2021-05-12
  • 2021-09-06
相关资源
相似解决方案