2015-05-03 135 views
0

我正在使用Parse庫和許多不同的庫項目開發Android應用程序。爲了導出apk文件,我使用了Pro Guard。雖然做apk文件的出口我收到以下錯誤:Proguard在apk導出時返回了錯誤代碼1

[2015-05-03 20:59:49 - SampleProject] Proguard returned with error code 1. See console 
[2015-05-03 20:59:49 - SampleProject] Warning: com.parse.FacebookAuthenticationProvider$1: can't find superclass or interface com.facebook.android.Facebook$ServiceListener 
[2015-05-03 20:59:49 - SampleProject] Warning: com.parse.FacebookAuthenticationProvider$2: can't find superclass or interface com.facebook.Session$StatusCallback 
[2015-05-03 20:59:49 - SampleProject] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find superclass or interface com.facebook.Request$Callback 
[2015-05-03 20:59:49 - SampleProject] Warning: org.hamcrest.generator.qdox.ant.AbstractQdoxTask: can't find superclass or interface org.apache.tools.ant.Task 
[2015-05-03 20:59:49 - SampleProject] Warning: org.hamcrest.integration.EasyMock2Adapter: can't find superclass or interface org.easymock.IArgumentMatcher 
[2015-05-03 20:59:49 - SampleProject] Warning: org.hamcrest.integration.JMock1Adapter: can't find superclass or interface org.jmock.core.Constraint 
[2015-05-03 20:59:49 - SampleProject] Warning: com.google.common.base.Equivalence: can't find referenced class javax.annotation.Nullable 
+0

請檢查下面link.It可能的幫助。 http://stackoverflow.com/questions/17218226/proguard-error-preventing-apk-from-building-with-returned-error-with-error-code –

回答

1

在你proguard-project.txt添加此-dontwarn和 - keep class線:

-keep class com.parse.*{ *; } 
-dontwarn com.parse.** 
-dontwarn com.google.common.** 
-dontwarn org.hamcrest.** 
相關問題