Download ant from ;
http://ant.apache.org/bindownload.cgi
Download the zip from the current release section.
Extract the contents and Set ANT_HOME by following;
Right click My Computer icon
Choose properties
Choose Advanced Tab
Choose Environtmen Variables Button
In the System Variables, click New Button
Give the Variable Name:ANT_HOME
Give the Value: C:Ant or where Ant has been installed on your local.
Click OK
Now we need to edit PATH in the Variable Column in System variables
Add
%ANT_HOME%bin;
in the last line of PATH veriable.
Check wheter ANT works by typing the following in command prompt;
ant -version
It should be something like;
Apache Ant version 1.7.1 compiled on June 27 2008
If you get messages like;
“Unable to locate tools.jar”, then don’t forget to set; JAVA_HOME variable as you did for ANT_HOME
when you give; echo %JAVA_HOME%, you should get something like;
C:Program FilesJavajdk1.6.0_14
Now give;
ant -version
You are good to go