Este contenido no está disponible en el idioma seleccionado.

Appendix C.  Installing Apache Ant


The Java build tool Apache Ant is not required for the installation or normal operation of the JBoss Enterprise Application Platform. However, it is occasionally needed for some configuration tasks and also for building and deploying some applications.

Note

If running a development workstation, Apache Ant may already be installed.

Note

To learn more about Apache Ant, visit the project's website at http://ant.apache.org.

Procedure C.1.  Installing Apache Ant on Red Hat Enterprise Linux

  • Download and install Apache Ant on Red Hat Enterprise Linux by issuing this command:
    [localhost]$ sudo yum install ant
    Copy to Clipboard Toggle word wrap

Procedure C.2.  Installing Apache Ant on Other Operating Systems

  1. Download and Extract

    Download the Apache Ant binary release from http://ant.apache.org/bindownload.cgi.
    Once it is downloaded, extract it into a preferred installation location, such as c:\Program Files\Apache\Ant\ or /opt/apache-ant-1.8/.
  2. Add the ANT_HOME Environmental Variable

    Next, create an environmental variable called ANT_HOME. This variable has to contain the path created in the previous step.
    • Do this on Red Hat Enterprise Linux/Hewlett-Packard HP-UX systems by adding the following line to the ~/.bash_profile file, substituting the path with that created above.
      export ANT_HOME=/opt/apache-ant-1.7.1
      Copy to Clipboard Toggle word wrap
    • On Microsoft Windows Server, do this by click on the Start Menu and opening the Control Panel then selecting System -> Advanced -> Environment Variables. Create a new variable named ANT_HOME and configure it to point to the ant directory.
  3. Include bin in the PATH

    Next, append the ant installation's bin directory the PATH environmental variable.
    • On Red Hat Enterprise Linux/Hewlett-Packard HP-UX systems, add the following line to the ~/.bash_profile file after the one which sets the ANT_HOME variable:
      export PATH=$PATH:$ANT_HOME/bin
      Copy to Clipboard Toggle word wrap
    • On Microsoft Windows Server, do this task by opening the Control Panel then selecting System -> Advanced -> Environment Variables->System Variables -> Path. Create a new variable, calling it ANT_HOME. Next, add a semicolon and %ANT_HOME%\bin to the end of the path value.
To test the Apache Ant installation, run ant -version from within a command line shell. The output should look similar to this:
[localhost]$ ant -version
Apache Ant version 1.8 compiled on June 27 2008
Copy to Clipboard Toggle word wrap
Volver arriba
Red Hat logoGithubredditYoutubeTwitter

Aprender

Pruebe, compre y venda

Comunidades

Acerca de la documentación de Red Hat

Ayudamos a los usuarios de Red Hat a innovar y alcanzar sus objetivos con nuestros productos y servicios con contenido en el que pueden confiar. Explore nuestras recientes actualizaciones.

Hacer que el código abierto sea más inclusivo

Red Hat se compromete a reemplazar el lenguaje problemático en nuestro código, documentación y propiedades web. Para más detalles, consulte el Blog de Red Hat.

Acerca de Red Hat

Ofrecemos soluciones reforzadas que facilitan a las empresas trabajar en plataformas y entornos, desde el centro de datos central hasta el perímetro de la red.

Theme

© 2025 Red Hat