ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Morten Mortensen <morten.morten...@tietoenator.com>
Subject RE: taskdef class org.apache.jasper.JspC cannot be found
Date Mon, 01 Sep 2003 12:41:54 GMT

Hi,

Try with "jasper-runtime.jar" and "jasper-compiler.jar" - for e.g. a 4.1.27
it solves all problems with missing classes. I *think*! -These archives are
in "...Tomcat/common/lib" - they are included in the classpath set up on
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jasper-howto.html#Web%20Appl
ication%20Compilation.

     -----

Actually, I do have some problems getting the "jspc"-task to work... To
define the task, I have tried with a task "external.tomcat.jasper.init" and
a reference to two local copies of "jasper-runtime.jar" and
"jasper-compiler.jar" -

  <property
    name="external.tomcat.jasper.classpath.dir"
    value="${spider.lib.dir}/Tomcat/4.1.27/Jasper"
  />

  <property
    name="external.tomcat.jasper.classpath"
 
value="${env.J2EE_HOME}/lib/j2ee.jar;${external.tomcat.jasper.classpath.dir}
/jasper-runtime.jar;${external.tomcat.jasper.classpath.dir}/jasper-compiler.
jar"
  />

  <target
    name="external.tomcat.jasper.init"
  >
    <taskdef
      name="tomcat-jspc"
      classname="org.apache.jasper.JspC"
      classpath="${external.tomcat.jasper.classpath}"
    />
  </target>

     -----

If you succeed - or find some documentation of the attributes to the
"jasper2"-task - give us a hint!

     :-)

Regards,
  Morten Sabroe Mortensen 

-----Original Message-----
From: William Abson [mailto:william.abson@db.com]
Sent: 1. september 2003 14:24
To: user@ant.apache.org
Subject: taskdef class org.apache.jasper.JspC cannot be found


Hi,

I'm trying to construct an Ant build file to precompile some JSPs in a
webapp running under Tomcat. I used the basic template for the build file
from

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jasper-howto.html#Web%20Appl
ication%20Compilation

When I tried running this using the command:

ant -Dtomcat.home=<tomcat.home> -Dwebapp.path=<webapp.home>

I received a 'class cannot be found' error for the class
org.apache.jasper.JspC which is referenced in the <taskdef> ant task as
follows:

<taskdef classname="org.apache.jasper.JspC" name="jasper2" >

I tried specifying a classpath attribute for the <taskdef> element to
explicitly point to the location of Tomcat's lib/catalina-compile.jar file
(which contains the JspC class), but I still get the error. I also put this
in the CLASSPATH in the script I'm using to execute the ant command, but to
no avail.

I'd be grateful for any advice on how I can get Ant to pick up the
org.apache.jasper.JspC class, if anyone has any experience of this?

I'm using Ant 1.5.4 and Tomcat 4.0.6.

Thanks,
Will.


--

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message