ORMLite 5.0构建失败

时间:2016-08-09 19:11:56

标签: android ormlite

当我升级到ORMLite的v.50和Android的ORMLite时,Proguard失败了警告。我对ORMLite的proguard配置如下:

-keep class com.j256.** { *; }
-keepclassmembers class com.j256.** { *; }
-keep enum com.j256.**
-keepclassmembers enum com.j256.** { *; }
-keep interface com.j256.**
-keepclassmembers interface com.j256.** { *; }
-keep class com.colorsnap.model.**
-keepclassmembers class com.colorsnap.model.** { *; }

日志

Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.LoggerFactory
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.LoggerFactory
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.logger.Slf4jLoggingLog: can't find referenced class org.slf4j.Logger
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Basic
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Id
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.GeneratedValue
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.OneToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.ManyToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Enumerated
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Version
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Basic
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.ManyToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.FetchType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Enumerated
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.EnumType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Entity
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Table
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Entity
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Table
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Basic
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Id
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.GeneratedValue
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.OneToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.ManyToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Enumerated
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Version
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.EnumType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Entity
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Table
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.FetchType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.EnumType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.FetchType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.EnumType
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Column
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Basic
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Id
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.GeneratedValue
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.OneToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.ManyToOne
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.JoinColumn
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Enumerated
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Version
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Entity
Warning: com.j256.ormlite.misc.JavaxPersistenceImpl: can't find referenced class javax.persistence.Table

1 个答案:

答案 0 :(得分:10)

添加以下内容对我有用:

-dontwarn org.slf4j.**
-dontwarn org.apache.log4j.**
-dontwarn org.apache.commons.logging.**
-dontwarn org.apache.commons.codec.binary.**
-dontwarn javax.persistence.**
-dontwarn javax.lang.**
-dontwarn javax.annotation.**
-dontwarn javax.tools.**