我想缩小spongycastle核心jar,但保留几个类及其依赖项。我使用proguard,但我只使用指定的类
这是我的配置:
-injars core-1.54.0.0.jar
-outjars core-1.54.0.0-shrinked.jar
-libraryjars /Users/abc/Library/Android/sdk/platforms/android-23/android.jar
-printmapping out.map
-dontpreverify
-dontobfuscate
-repackageclasses ''
-allowaccessmodification
-optimizations !code/simplification/arithmetic
-keepparameternames
-renamesourcefileattribute SourceFile
-keepattributes Exceptions,InnerClasses,Signature,Deprecated,
SourceFile,LineNumberTable,*Annotation*,EnclosingMethod
-keep public class org.spongycastle.crypto.BlockCipher
-keep public class org.spongycastle.crypto.engines.AESFastEngine
-keep public class org.spongycastle.crypto.macs.CMac
-keep public class org.spongycastle.crypto.params.KeyParameter