Proguard is not supporting the ant

I am using the ant 1.10.7 and ProGurad 7.1.0-beta5.jar. In the build path I copied the proguard core jar. after running the ant all, I am getting the “Could not load definitions from resource proguard/ant/task.properties. It could not be found.” error. Could someone please help me understand this. Thanks in Advance.

1 Like

Hi @ajay.jayavarapu,

First of all, welcome to the ProGuard community!

Regarding your question;
The problem seems to be that you’re using the proguard-core jar and not theproguard-ant.jar. The task.properties file should be accessible from inside the proguard-ant.jar. But of course this means you need to use the proguard-ant.jar like this:

<taskdef resource="proguard/ant/task.properties" classpath="${proguard.path}/lib/proguard-ant.jar" />

And not the proguard-core.jar

Also important to note, is that this path is to a file inside the proguard-ant.jar , not on the file system, so you wont see that file somewhere. (e.g: resource="proguard/ant/task.properties")

You can find this documented in the ProGuard Manual:

Please let me know if anything is not clear.

Kind Regards,

Jack