ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mikael Petterson (KI/EAB)" <mikael.petter...@ericsson.com>
Subject Why is not jalopy target executed?
Date Wed, 23 Jun 2004 13:22:11 GMT
Hi!

why is not jalopy target executed? I get no error messages.

any hints?

//Mikael 


<?xml version="1.0" encoding="UTF-8"?>
<!-- History:                                                                     -->
<!-- 2004-06-22 eraonel add task for jalopy and remove unncesseceray xml          -->
<!-- 					                                          -->
<!--                                                                              -->
<project basedir="." default="all" name="xml2j">

   
  <!-- ==================================================================== -->
  <!-- initialize properties                                                -->
  <!-- ==================================================================== -->
    <target name="init">
        <!-- You can set up any variables you want used throughout the script here. -->
         
         <!-- create the timestamp -->
         <tstamp/>
       
	 <!-- boam specific params -->
	 <property name="xsl.file" value="interface.xsl"/>
         <property name="xml.file" value="rbsmom.xml"/>
         <property name="incr" value="wega4.0"/>
	 <property name="gen.pkg" value="se/ericsson/wcdma/rbs/boam/mao/iface/mo"/>
         <property name="output.dir" value="/vobs/rbs/sw/rbssw_tools/boam_tools/xml2j/output"/>
	 <echo message="output dir is ${output.dir}"/>
	 <echo message="template file is ${xsl.file}!"/>
	 <echo message="package is ${gen.pkg}"/>
	
         <!-- xml2j directories -->
	 <property name="xml2j.home" value="/vobs/rbs/sw/rbssw_tools/boam_tools/xml2j"/>
         <property name="src.dir" value="${xml2j.home}/src"/>
         <property name="dest.dir" value="${xml2j.home}/classes"/>
         <property name="lib.dir" value="${xml2j.home}/lib"/>
         <property name="xsl.dir" value="${xml2j.home}/xsl"/>
         <property name="xml.dir" value="${xml2j.home}/xml"/>
	 <property name="bin.dir" value="${xml2j.home}/bin"/>
	 
         <!-- jalopy directories -->
	 <property name="jalopy.ant.dir" value="/vobs/rbs/sw/rbssw_tools/boam_tools/jalopy-ant"/>
	 <property name="jalopy.dir" value="/vobs/rbs/sw/rbssw_tools/boam_tools/jalopy"/>
        
         <!-- defines a jalopy task -->
	 <taskdef name="jalopy" classname="de.hunsicker.jalopy.plugin.ant.AntPlugin">
       	   <classpath>
             <fileset dir="${jalopy.ant.dir}/lib">
               <include name="*.jar" />
             </fileset>
           </classpath>
  	 </taskdef> 
         
         <!-- classpath for project -->
         <path id="classpath">
	  <pathelement location="${lib.dir}/xalan.jar"/>
          <pathelement location="${lib.dir}/xml-apis.jar"/>
          <pathelement location="${lib.dir}/xercesImpl.jar"/>
	  <pathelement path="${dest.dir}"/>
         </path>
    </target>
  <!-- ==================================================================== -->
  <!-- Compiles the project sources                                         -->
  <!-- ==================================================================== -->
   
   <target depends="init" name="compile">
    <echo message="Compiling with ${ant.java.version}!"/>
        <!-- Both srcdir and destdir should be package roots. -->
       	 <javac debug="true" deprecation="true" destdir="${dest.dir}" srcdir="${src.dir}">
            <!-- To add something to the classpath: -->
             <classpath refid="classpath"/>
	</javac>
   </target>

  <!-- ==================================================================== -->
  <!-- Generate java source files                                           -->
  <!-- ==================================================================== --> 
    
    <target depends="compile" description="execute ${ant.project.name} application." name="execute">
        <java  classname="se.ericsson.xml2j.common.Main"
          failonerror="true" fork="true">
            <classpath refid="classpath"/>
            <!-- Pass some args:--> 
            <arg value="${xsl.dir}/${xsl.file}"/>
	    <arg value="${xml.dir}/${xml.file}"/>
	    <arg value="${incr}"/>
	    <arg value="${gen.pkg}"/>
	    <arg value="${output.dir}"/>
	</java>
       <echo message="Files generated!"/>
    </target>

  <!-- ==================================================================== -->
  <!-- Initialize uninitialized String and int.                             -->
  <!-- ==================================================================== -->    

  <target depends="execute" description="Run replace.sh" name="replace">
       <exec dir="${bin.dir}" executable="replace.sh">
        <arg value="${output.dir}/${gen.pkg}"/>	
       </exec>
       <echo message="String:s and int:s initialized!"/>
  </target>
  <!-- ==================================================================== -->
  <!-- Formats all generated source files                                   -->
  <!-- ==================================================================== -->
  <target  depends="replace" description="format code according to sun conv." name="format">
    <!--

      Invokes Jalopy as follows:

      - All formatted files will have unix fileformat (\n)
      - Load your code convention from the given url
      - Override the convention to use the file history feature
      - Override the convention to use alder32 checksums of files for history testing
      - Override the convention to use loglevel "info"
      - Override the convention to use 2 threads
      - The import optimization feature will work (if enabled in the active
        convention), because a classpath reference is specified

        Don't forget to setup an include pattern as Jalopy truly expects
        valid Java source files as input!

      -->
    <echo message="files are in ${output.dir}/${gen.pkg}"/>
    <jalopy fileformat="unix"
            convention="${jalopy.dir}/cfg/sun.xml"
            history="file"
	    historymethod="adler32"
	    threads="2"
            loglevel="error">
        <fileset dir="${output.dir}/${gen.pkg}">
        <include name="**/*.java" />
      </fileset>
    </jalopy>
  </target> 
   
  <!-- ==================================================================== -->
  <!-- build all                                                            -->
  <!-- ==================================================================== -->
    <target depends="format" description="Build everything." name="all">
        <echo message="${ant.project.name} built and files generated"/>
    </target>   
  <!-- ==================================================================== -->
  <!-- clean  all class files                                               -->
  <!-- ==================================================================== -->	
    <target depends="init" description="Clean all build products." name="clean">
        <delete>
            <fileset dir="${dest.dir}">
                <include name="**/*.class"/>
            </fileset>
        </delete>
    </target>

</project>

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


Mime
View raw message