Installing Ant on Windows XP

Pēdējais mainījis Administrator 2011-06-06 17:26

Installing Ant on Windows XP

Windows #recipelabel($translation,"${docname}_${translation}")

Ant is a build tool that allows executing build scripts. The Ant scripts consist of build targets containing tasks (various development-related file manipulations such as copying, archiving, compilation). Ant allows also customized, user-specific tasks.

  1. Unzip file apache-ant-1.7.1-bin.zip, e.g. under c:/tools
  2. Define a new environment variable ANT_HOME = c:/tools/apache-ant-1.7.1 like this:
    REG QUERY "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment" /v "JAVA_HOME"
    REG ADD "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment" /v "ANT_HOME" /d "c:/tools/apache-ant-1.7.1"
    The first command should read the JAVA_HOME variable - the place where Java is installed. Second one sets the ANT_HOME variable.
  3. Add another directory to the PATH variable - i.e. add before all other path entries %ANT_HOME%bin and separate it from the next PATH values by a semicolon (;)
    REG ADD "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment" /v "PATH" /d "%ANT_HOME\bin";%PATH%
  4. You can also set the environment variables manually by WinKey + Pause > Advanced > Environment Variables and editing System variables (which are preferable to the user ones) - see references below.

Links

  1. Manually Setting Windows Environment Variables

Tags:  

Tagi:
Izveidojis Kalvis Apsītis 2009-07-18 11:05
    
This wiki is licensed under a Creative Commons 2.0 license
XWiki Enterprise 6.4 - Documentation