[6.0.1] Multiple "classes" directories when using Gradle plugin
Java class file shrinker, optimizer, obfuscator, and preverifier
Brought to you by:
guardsquare
Version 6.0.1 works fine with our code and configuration, thanks for that! However, the Gradle plugin (or ProGuard itself, not sure) puts the output in 2 nested "classes" directories more than needed. I have the following configuration:
outjars "/home/boris/project/build/obfuscated/classes"
But ProGuard puts the output in "/home/boris/project/build/obfuscated/classes/classes/classes" instead. This is a regression from 5.3.3.
I encountered the same problem and I think the problem comes from DataEntryWriterFactory.createClassPathEntryWriter method as it adds "classes/" prefix twice before jar writer. I think the intention of the code was different but I do not foresee how to fix it clearly.
I've got the same problem when using the ProGuard Ant task from Maven. As a symptom, the subsequent compilation of test classes fails.
Last edit: Hendrik Schreiber 2018-04-01
Unfortunately the same problem also happens in 6.0.2 and as Hendrik says, this renders ProGuard unusable as the project cannot be built after that.
I can see the issue now. I'll fix it for update 6.0.3. It only happens if you write the output to a directory. As a workaround, you can write the output to a jar.
Last edit: Eric Lafortune 2018-04-01
Thank you so much for the support!
Awesome, Eric! 👍
This issue has been resolved, thanks!
Fixed in ProGuard 6.0.3.