Ying,

>  <apply executable="java">

Why use <apply..>? Why not <java..>? 

>  <fileset dir="${client}/web/fit" includes="**/*.jsp/**"/>

I think the includes should be "**/*.jsp". 
The following target works for me with Weblogic 6 and Ant 1.4/1.5. You can try if it 
works for you with your local settings:

  <target name="jspcompile" depends="setclasspaths" if="jspc_classpath">
    <java classname="weblogic.jspc" fork="yes" classpathref="wl_classpath">
      <arg value="-verbose" />
      <arg value="-depend" />
      <arg value="-deprecation" />
      <arg line="-d ${dir.home}\WEB-INF" />
      <arg line="-webapp ${dir.home}" />
      <arg line="-classpath ${jspc_classpath}" />
      <arg line="${jsp.files}" />

    </java>
  </target>

The depend argument makes weblogic.jspc compile only if the jsp has been modified.

The following ejbjar works for me in the same environment and you can try that too.
 <target name="genEjb" depends="compile" >
    <ejbjar descriptordir="${dir.src}"
            srcdir="${dir.classes}"
            naming="basejarname"
            basejarname="${ejbname}"
            flatdestdir="true" >
      <include name="**/ejb-jar.xml" />
      <exclude name="**/*weblogic*.xml" />
      <weblogic destdir="${dir.dist}" newCMP="true" >
        <classpath>
          <path refid="build_classpath" />
        </classpath>
        <wlclasspath>
          <path refid="build_classpath" />
        </wlclasspath>
      </weblogic>
       <dtd publicId="-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN"
          location="${dir.lib}/ejb-jar_1_1.dtd" />
       <dtd publicId="-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN"
          location="${dir.lib}/weblogic-ejb-jar.dtd" />
    </ejbjar>
  </target>


-Milind




> -----Original Message-----
> From: Ying Wang [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, August 13, 2002 10:15 PM
> To: Ant Users List
> Subject: jsp precompile with weblogic5.1 and ant1.4
> 
> 
> Hello Everyone,
>    The situation is I got serveral ways , but none of them solve the
> problem:
> 
>    1. I use weblogic.jspc (5.1) and ant 1.4 :
>    Source code :
> 
> <target name="jspcompile" >
>  <apply executable="java">
>  <arg line="weblogic.jspc -compiler javac -g -d ${client}/web/WEB-INF
> -docroot ${client}/web -classpath ${jspc-classpath} -verbose }"/>
>  <fileset dir="${client}/web/fit" includes="**/*.jsp/**"/>
>  </apply>
> </target>
> 
>    This one does compile jsp pages and the geverated java 
> files. But it
> can not check if the jsp have changed. How to make it check 
> the uptodate
> for each jsp file? I use the uptodate, but I need to go 
> through all the
> jsp. Then I have problem to use for each.
> 
>    And the weblogic server still generate the java file. How to
> stop it?
> 
>   2. I try to use ant1.5, but the ejbjar task won't work!!!
>      [ejbjar] Unable to load dependency analyzer:
> org.apache.tools.ant.util.depend.bcel.AncestorAnalyzer
> 
>    Also the <wljspc> won't work too!!!
>    Source code:
> <target name="jspcompile3" >
>   <wljspc src="${client}/web/fit" dest="${client}/web/fit/WEB-INF"
> package="Authenticate.jsp" classpath="${jspc-classpath}"/>
> </target>
> 
>   The error is:
> 
>  [wljspc] The args attribute is deprecated. Please use nested arg
> elements.
> 
>    And I read the document , that is what I am using
> 
> Need help!!!!!!!!
> 
> Thanks a lot,
> Ying Wang
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: 
> <mailto:[EMAIL PROTECTED]>
> 
> 

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to