Sun GlassFish Web Space Server 10.0 Administration Guide

ProcedureTo Set the ANT_HOME Variable on a Linux or Macintosh System

  1. In your home folder, open the .bash_profile file in the root directory.

  2. Add the following lines to the file, substituting the directory where you installed Ant:

    ANT_HOME=/apache-install-dir/apache-ant-version
    ANT_OPTS="-Xms256M -Xmx512M"
    PATH=$PATH:$HOME/bin:$ANT_HOME/bin
    export ANT_HOME ANT_OPTS PATH
  3. To test the setting, type ant at a command prompt and press Return.

    • If a Build not found error message appears, you have correctly installed Ant.

    • If you do not see an error message, check the environment variable settings and make sure they are pointing to the correct directory locations.