$Id: BUILDING.txt,v 1.3 2002/07/16 19:30:51 kinman Exp $

         Building The Tomcat 4.0 Servlet/JSP Container With Jasper2
         ==========================================================

Jasper2 is a reimplementation of the JSP Container for Tomcat 4.0 that is
cleaner and easier to extend.  It also forms the basis of the JSP 2.0 
implementation.  Jasper2 will eventually replace the Jasper module
built into the Tomcat distribution.  In the meanwhile, you can build Jasper2
alongside Tomcat 4.0 and replace Jasper.

To build Jasper2, first make sure you have a working build environment for
Tomcat 4.0.  You can do so by following the instructions in the BUILDING.txt
file in the Tomcat 4.0 workspace.

Once you have a working build environment for Tomcat 4.0, do the following:

(0) Modify your build.properties file in Tomcat 4.0

* Add a line to your build.properties file for Tomcat 4.0 that
  points the build script to Jasper2 instead of Jasper, as follows:

      # ----- Jakarta Tomcat Jasper source path -----
      jasper.home=${base.path}/jakarta-tomcat-jasper/jasper2

  This directory is relative to the location of build.xml for Tomcat.

(1) Use anonymous CVS (as described on the Jakarta web site at
    <http://jakarta.apache.org/site/cvsindex.html>, or download a source
    distribution of the "jakarta-taglibs" repository (7/15/2002 or later).

    http://jakarta.apache.org/builds/jakarta-taglibs/nightly/projects/standard/

* Unpack the package into a convenient location so that
  it resides in its own subdirectory.

* Follow the instructions in BUILDING.txt to set up the correct 
  build environment.  Make sure you have a valid build.properties file.

* Change directory to "standard" and build the special JSP 2.0 build target
  for producing the JSP 2.0 Expression Language Evaluator.  The ant target
  is called jsp20el.dist.

        cd standard
        ant jsp20el.dist

(2) Customize Build Properties for this subproject

Most Jakarta subprojects allow you to customize Ant properties (with default
values defined in the "build.xml" file.  This is done by creating a text file
named "build.properties" in the source distribution directory (for property
definitions local to this subproject) and/or your user home directory (for
property definitions shared across subprojects).  You can use the included
"build.properties.sample" file as a starting point for this.

Jasper2 has external dependencies that are satisfied by configuring
appropriate values in your build.properties file.  The easiest
way to satisfy these dependencies is to copy the "build.properties.sample"
file (in the top-level Tomcat source directory) to "build.properties", and
then edit it to suit your environment.  On Unix, this would be done as:

  cd ${jasper2.source}
  cp build.properties.sample build.properties
  emacs build.properties

NOTE:  Be *sure* that you do not check "build.properties" in to the CVS
repository.  This file is local to your own development environment, and
each developer will have their own version.

(3) Build A Binary Distribution

Jasper2 is built as part of Tomcat.  Follow the instructions in 
BUILDING.txt in the Tomcat project to build Tomcat with Jasper2.
