ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rob Moore" <robmo...@yahoo.com>
Subject Re: Tomcat JSPC Precompile using Ant - unique jsp name problem
Date Thu, 03 Apr 2003 14:42:56 GMT
FWIW, I tried using the Ant task included with 4.1.24 and it works very
well.

Take a look at:

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jasper/docs/api/org/apache/j
asper/JspC.html

It does have some drawbacks (like you can't use classpathref, apparently),
but it is the closest I've found to getting the desired result. At any rate,
it behaves well WRT packages.

P.S. Here's the relevant section from the docs:

 <taskdef classname="org.apache.jasper.JspC" name="jasper2" >
        <classpath>
            <pathelement location="${java.home}/../lib/tools.jar"/>
            <fileset dir="${ENV.CATALINA_HOME}/server/lib">
                <include name="*.jar"/>
            </fileset>
            <fileset dir="${ENV.CATALINA_HOME}/common/lib">
                <include name="*.jar"/>
            </fileset>
            <path refid="myjars"/>
         </classpath>
    </taskdef>

    <jasper2 verbose="0"
             package="my.package"
             uriroot="${webapps.dir}/${webapp.name}"
             webXmlFragment="${build.dir}/generated_web.xml"
             outputDir="${webapp.dir}/${webapp.name}/WEB-INF/src/my/package"
/>




Mime
View raw message