proguard.config=${sdk.dir}/tools/proguard/proguard-androID.txt:proguard-project.txt
工作准备工作正常工作.
但是当我添加了androID-support-v4.jar库时,在导出签名的应用程序项目时出错
Launch canceled! Proguard returned with error code 1. See console Note: there were 316 duplicate class deFinitions. Warning: com.Google.androID.gms.common.images.ImageManager$a: can't find superclass or interface androID.content.ComponentCallbacks2 Warning: com.Google.androID.gms.maps.MapFragment: can't find superclass or interface androID.app.Fragment Warning: com.Google.androID.gms.common.GooglePlayServicesUtil: can't find referenced fIEld 'int smallestScreenWIDthDp' in class androID.content.res.Configuration Warning: com.Google.androID.gms.common.images.ImageManager: can't find referenced method 'voID registerComponentCallbacks(androID.content.ComponentCallbacks)' in class androID.content.Context Warning: com.Google.androID.gms.common.images.ImageManager$a: can't find referenced class androID.content.ComponentCallbacks2 Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$a: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$a: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$b: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$b: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$b: can't find referenced class androID.app.Fragment Warning: com.Google.androID.gms.maps.MapFragment$b: can't find referenced class androID.app.Fragment You should check if you need to specify additional program jars. Warning: there were 21 unresolved references to classes or interfaces. You may need to specify additional library jars (using '-libraryjars'). Warning: there were 2 unresolved references to program class members. Your input classes appear to be inconsistent. You may need to recompile them and try again. Alternatively,you may have to specify the option '-dontskipnonpubliclibraryclassmembers'. java.io.IOException: Please correct the above warnings first.at proguard.Initializer.execute(Initializer.java:321)at proguard.ProGuard.initialize(ProGuard.java:211)at proguard.ProGuard.execute(ProGuard.java:86)at proguard.ProGuard.main(ProGuard.java:492)
我试图添加以下行proguard-project.txt,但它不工作
-dontwarn androID.support.**-dontwarn com.Google.ads.**-libraryjars libs/androID-support-v4.jar-keep public class * extends com.phonegap.API.Plugin -keep public class org.apache.cordova.DroIDGap -keep public class org.apache.cordova.** -dontwarn androID.webkit.*-dontwarn org.apache.**-dontwarn androID.support.v7.Widget.**-keep class androID.support.v7.Widget.** { *; }-dontwarn com.Google.ads.** -keep class com.Google.ads.** {*;}-keep class com.Google.androID.gms.analytics.**-keep class com.Google.analytics.tracking.**-dontwarn com.Google.androID.gms.analytics.**-dontwarn com.Google.analytics.tracking.**-keep class com.Google.ads.** { *; }-dontwarn com.Google.ads.**-keep public class com.admob.androID.ads.** {*;}解决方法 我自己找到答案
在proguard-project.txt文件中添加以下2行解决了问题.
-dontwarn com.Google.androID.gms.*-ignorewarnings总结
以上是内存溢出为你收集整理的Android项目:导出问题启动取消! Proguard返回错误代码1.请参阅控制台全部内容,希望文章能够帮你解决Android项目:导出问题启动取消! Proguard返回错误代码1.请参阅控制台所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)