Ant is a Java-based build tool .It there is much more to building software than just typing in and then compiling the source code.
# Get the source. You may need to download or fetch the source from a source code repository.
# Prepare a build area. You will probably want to create a set of directories, perhaps according to some standardized directory layout.
# Configure the build and determine what optional components can be built
based on the current environment.
# Validate the source code. You may have a standard style guide and you wish to ensure all code conforms to this before you build a release.
# Compile the source code
For read more information,Examples and Tutorials on Ant visit to :http://www.roseindia.net/tutorials/ant/