# ANT\_HOME environment variable not set

**URL:** https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211
**Category:** Discussion
**Created:** [October 23, 2013, 10:54am UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211 "2013-10-23T10:54:45Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![davestiff](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/d/f08c70/32.png) [@davestiff](https://www.finalbuilder.com/forums/u/davestiff)
#### Post date: [October 23, 2013, 10:54am UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211/1 "2013-10-23T10:54:45Z")

</div>

Hi,

&nbsp;I have this variable set in the User and System variables. Not sure why I get this error when running an Ant action.

Error&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Ant Project&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Ant Project&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | 16:42:06&nbsp;&nbsp; | 16:42:06 | 00:00:00 |  
---------------|--------------------------|---------------------------------------------------------------------------------|------------|----------|----------|  
ANT\_HOME environment variable not set.

My variables are:

> > > ANT\_HOME=C:\Program Files\apache-ant-1.9.2
> > > 
> > > JAVA\_HOME=C:\Program Files (x86)\Java\jdk1.6.0\_30

Please advise.

Thanks,

Dave

Windows 2008 Server R2 64-bit

FinalBuilder 7 Build 2538

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [October 24, 2013, 12:11pm UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211/2 "2013-10-24T12:11:45Z")

</div>

You need to make the variable available as an Environment Variable. There is an option for this on the edit variable form.

---

<div class="post-metadata">

### Author: ![davestiff](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/d/f08c70/32.png) [@davestiff](https://www.finalbuilder.com/forums/u/davestiff)
#### Post date: [October 24, 2013, 2:32am UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211/3 "2013-10-24T02:32:36Z")

</div>

Hi,

&nbsp;I don't think I understand. I have ANT\_HOME defined as a&nbsp; Windows Environment Variable and it displays in the list in FinalBuilder:

Attachment unavailable

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [October 24, 2013, 2:50am UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211/4 "2013-10-24T02:50:31Z")

</div>

That should be enough. Processes started from FinalBuilder get the same environment block as it has, plus any additional env vars it defines. Did you define the variable for all users or current user? Is the build running under the same user?   
  
 Try running a dos command action, make the command : set   
  
 and see what variables are listed.

---

<div class="post-metadata">

### Author: ![davestiff](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/d/f08c70/32.png) [@davestiff](https://www.finalbuilder.com/forums/u/davestiff)
#### Post date: [October 24, 2013, 3:08am UTC](https://www.finalbuilder.com/forums/t/ant-home-environment-variable-not-set/2211/5 "2013-10-24T03:08:12Z")

</div>

Hi,

I rebooted the machine and FinalBuilder is using the Environment Variables now.

Thanks,

Dave
