I'm building APK files using gradle and let proguard shrink and obfuscate my code. One external library that I use contains some *.so files that I do not need but that end up in my final APK file.
I guess it should be possible to tell proguard to ignore those files, but how?
The documentation of proguard (http://proguard.sourceforge.net/manual/usage.html#filters) explains how to use filters, for example this is how to avoid errors with duplicate MANIFEST files:
-injars in1.jar
-injars in2.jar(!META-INF/MANIFEST.MF)
-injars in3.jar(!META-INF/MANIFEST.MF)
-outjars out.jar
And we can also filter based on filenames and patterns:
-injars in.jar(!images/**)
-outjars out.jar
This would be perfect, let's assume I wanted to do exactly as in the second example and strip everything in an 'images' directory from one of my jars.
The problem is, when using proguard in a gradle build for an Android project, we don't specify the input and output ourselves as in these examples. Instead probably gradle tells proguard which JARs to work on and where to write the results to. So there is no place in the config file to put the
(!images/**)
statement.
What I would expect to work is an option similar to this one:
-stripfiles !images/**