web-dev-qa-db-fra.com

ProGuard ne trouve pas les bibliothèques référencées

[2014-07-15 23:57:43 - MozMeet] Proguard returned with error code 1. See console
[2014-07-15 23:57:43 - MozMeet] Note: there were 662 duplicate class definitions.
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$1: can't find superclass or interface com.facebook.Android.Facebook$ServiceListener
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find superclass or interface com.facebook.Session$StatusCallback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find superclass or interface com.facebook.Request$Callback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$Builder
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$Builder
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$Builder
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.SharedPreferencesTokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.SharedPreferencesTokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$Builder
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$Builder
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook$ServiceListener
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$StatusCallback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.SessionDefaultAudience
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session$OpenRequest
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.TokenCachingStrategy
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$1: can't find referenced class com.facebook.Android.Facebook$ServiceListener
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$1: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$1: can't find referenced class com.facebook.Android.FacebookError
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$1: can't find referenced class com.facebook.Android.FacebookError
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Session$StatusCallback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request$Callback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2: can't find referenced class com.facebook.SessionState
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Response
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.FacebookRequestError
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Response
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.model.GraphObject
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Request$Callback
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Response
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.FacebookRequestError
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.model.GraphObject
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Request
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Response
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.FacebookAuthenticationProvider$2$1: can't find referenced class com.facebook.Response
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Android.Facebook
[2014-07-15 23:57:43 - MozMeet] Warning: com.parse.ParseFacebookUtils: can't find referenced class com.facebook.Session
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkUrlFactory
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.Cache
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.Cache
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkUrlFactory
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkUrlFactory
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkUrlFactory
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkUrlFactory
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet] Warning: com.squareup.picasso.OkHttpDownloader: can't find referenced class com.squareup.okhttp.OkHttpClient
[2014-07-15 23:57:43 - MozMeet]       You should check if you need to specify additional program jars.
[2014-07-15 23:57:43 - MozMeet] Warning: there were 95 unresolved references to classes or interfaces.
[2014-07-15 23:57:43 - MozMeet]          You may need to specify additional library jars (using '-libraryjars').
[2014-07-15 23:57:43 - MozMeet] Error: Please correct the above warnings first.  

Voici la liste des erreurs que j'obtiens lorsque j'essaie d'exporter mon Android avec ProGuard activée. Un peu de recherche sur Google et j'ai constaté que je devais ajouter des fichiers jar à la proguard-project.txt. Jusqu'à présent, ce que j'ai ajouté ressemble à ceci (mais en vain):

-keepattributes SourceFile,LineNumberTable
-keep class com.parse.*{ *; }
-libraryjars \libs\Parse-1.5.1.jar
-keepclasseswithmembernames class * {
    native <methods>;
}  

J'ai également 3 autres bibliothèques avec Parse, à savoir Crashlytics, Picasso et V4 Support.

36
Little Child

Apporté quelques modifications à proguard-project.txt fichier (si vous avez plus d'un module dans votre projet - placez-le dans le module qui appelle le fichier * .jar qui vous avertit):

-keepattributes SourceFile,LineNumberTable
-keep class com.parse.*{ *; }
-dontwarn com.parse.**
-dontwarn com.squareup.picasso.**
-keepclasseswithmembernames class * {
    native <methods>;
}  

Le -dontwarn lignes étaient nécessaires. Fondamentalement, ce qu'ils disent ProGuard, c'est que ces pots fonctionnent bien par eux-mêmes, alors ne vous plaignez pas lorsque vous ne trouvez pas les classes auxquelles ils font référence.

82
Little Child