user1560801
user1560801

Reputation:

Unable to install Apache Ant

i have downloaded the Apache Ant file "apache-ant-1.8.4-bin.zip" from the following link :- http://ant.apache.org/bindownload.cgi. then i have added an environment variable to my windows 7 operating system:-

Name = ANT_HOME Value = C:\

but when i typed the following using CMD command line:-

C:\apache-ant-1.8.4-bin\apache-ant-1.8.4\bin>ant.bat

i got the following error: -

ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME.

So what might be going wrong? BR

Upvotes: 1

Views: 1088

Answers (2)

JasonRobinson
JasonRobinson

Reputation: 107

Per Krestens answer, your ANT_HOME variable needs to be the base dir where ant was unzipped. Then your PATH (either user or system) needs to add

%ANT_HOME%\bin;

That will allow you to call ant.bat (how ant starts on a windows system).

Upvotes: 0

Kresten Kjaer
Kresten Kjaer

Reputation: 21

Your ant home is:

C:\apache-ant-1.8.4-bin\apache-ant-1.8.4\

Create environment variable ANT_HOME with this value. Don't forget to re-open cmd window after.

Upvotes: 2

Related Questions