Proguard错误,无法导出app

时间:2013-01-25 07:27:13

标签: android proguard

[2013-01-25 15:20:55 - CQAQI] Proguard returned with error code 1. See console
[2013-01-25 15:20:55 - CQAQI] Note: there were 208 duplicate class definitions.
[2013-01-25 15:20:55 - CQAQI] Warning: android.support.v4.view.ViewCompatJellybeanMr1: can't find referenced method 'int getLabelFor()' in class android.view.View
[2013-01-25 15:20:55 - CQAQI] Warning: android.support.v4.view.ViewCompatJellybeanMr1: can't find referenced method 'void setLabelFor(int)' in class android.view.View
[2013-01-25 15:20:55 - CQAQI] Warning: there were 2 unresolved references to program class members.
[2013-01-25 15:20:55 - CQAQI]          Your input classes appear to be inconsistent.
[2013-01-25 15:20:55 - CQAQI]          You may need to recompile them and try again.
[2013-01-25 15:20:55 - CQAQI]          Alternatively, you may have to specify the option 
[2013-01-25 15:20:55 - CQAQI]          '-dontskipnonpubliclibraryclassmembers'.
[2013-01-25 15:20:55 - CQAQI] Error: Please correct the above warnings first.

当我导出应用程序时,即使在更新到Proguard 4.8之后,我也会收到错误。我该怎么办?

2 个答案:

答案 0 :(得分:4)

试试这个:

-dontwarn android.support.v4.view.**
-keep class android.support.v4.** { *; }

答案 1 :(得分:1)

我有同样的错误。
使用SDK级别4.2.2进行构建对我有用!