Subversion Repositories SmartDukaan

Rev

Blame | Last modification | View Log | RSS feed

<?xml version="1.0"?>


<!-- ====================================================================== 
     Date:     November 2010
     
     Project:  DtrApi
     
     Author:   Rajveer Singh
     ====================================================================== -->



<project name="DtrApi" default="archive" basedir=".">

        <description>
           Shop2020 DtrApi
    </description>

        <property file="build.properties"/>

        <filelist id="apache.libs" dir="${basedir}/${thirdparty.location}/readonly/apache">
                <file name="commons-collections-3.2.1/commons-collections-3.2.1.jar"/>
                <file name="commons-digester-2.0/commons-digester-2.0.jar"/>
                <file name="commons-fileupload-1.2.1/commons-fileupload-1.2.1.jar"/>
                <file name="commons-io-1.3.2/commons-io-1.3.2.jar"/>
                <file name="commons-lang-2.4/commons-lang-2.4.jar"/>
                <file name="commons-logging-1.0.4/commons-logging-1.0.4.jar"/>
                <file name="commons-logging-api-1.1/commons-logging-api-1.1.jar"/>
                <file name="commons-validator-1.3.1/commons-validator-1.3.1.jar"/>
                <file name="ezmorph/ezmorph-1.0.3.jar"/>
                <file name="json/json-lib-2.1-jdk15.jar"/>
                <file name="jsp-2.1/jsp-api.jar"/>
                <file name="ognl/ognl-2.7.3.jar"/>
                <file name="poi-3.7/poi-3.7-20101029.jar"/>
                <file name="struts-2.1.8.1/struts2-convention-plugin-2.1.8.1.jar"/>
                <file name="struts-2.1.8.1/struts2-core-2.1.8.1.jar"/>
                <file name="struts-2.1.8.1/struts2-rest-plugin-2.1.8.1.jar"/>
                <file name="struts-2.1.8.1/xstream-1.2.2.jar"/>
                <file name="struts-2.1.8.1/xwork-core-2.1.6.jar"/>
                <file name="thrift-0.2.0/libthrift.jar"/>
                <file name="tomcat-juli/tomcat-juli.jar"/>
                <file name="velocity-1.6.3/velocity-1.6.3.jar"/>
                <file name="velocity-1.6.3/velocity-tools-1.4.jar"/>
                <file name="xpp/xpp3_min-1.1.3.4.O.jar"/>
        </filelist>
        
        <filelist id="DtrApi.libs" dir="${basedir}/${thirdparty.location}">
                <file name="readonly/freemarker/freemarker-2.3.15.jar"/>
                <file name="readonly/slf4j/slf4j-api-1.5.8.jar"/>
                <file name="readonly/slf4j/slf4j-simple-1.5.8.jar"/>
                <file name="readonly/iText/iText-5.0.4.jar"/>
                <file name="Common.jar"/>
                <file name="ThriftConfig.jar"/>
        </filelist>

        <path id="DtrApi.classpath">
                <pathelement location="build/classes"/>
                <filelist refid="apache.libs"/>
                <filelist refid="DtrApi.libs"/>
                <pathelement location="${basedir}/${thirdparty.location}/readonly/apache/sevlet-2.5/servlet-api.jar"/>
        </path>
        
        <!-- ==================== Clean Target ==================================== -->

        <!--
          The "clean" target deletes any previous "build" and "dist" directory,
          so that you can be ensured the application can be built from scratch.
        -->
        <target name="clean" description="Delete old build and dist directories">
                <delete dir="${dist.home}"/>
                <delete dir="${build.home}"/>
        </target>

        <!-- ==================== Init Target ================================== -->

        <!--

          The "init" target is used to create the "build" destination directory,
          Normally, this task is executed indirectly when needed.

        -->
        <target name="init" description="Create build directory">

                <mkdir dir="${build.home}" />

        </target>

        <!-- ==================== Compile Target ================================== -->

        <!--

          The "compile" target transforms source files (from your "src" directory)
          into class files in the appropriate location in the build directory.
          This example assumes that you will be including your classes in an
          unpacked directory hierarchy under "/WEB-INF/classes".

        -->
        <target name="compile" depends="init" description="Compile Java sources">
                <mkdir dir="${build.home}/WEB-INF/classes" />
                <mkdir dir="${build.home}/WEB-INF/lib" />
                <javac srcdir="${source.home}"
                                destdir="${build.home}/WEB-INF/classes"
                                debug="${compile.debug}"
                                deprecation="${compile.deprecation}"
                                optimize="${compile.optimize}"
                             source="1.6" target="1.6">
                        <classpath refid="DtrApi.classpath"/>
                </javac>
                <javac srcdir="${conf.home}"
                                                destdir="${build.home}/WEB-INF/classes"
                                                debug="${compile.debug}"
                                                deprecation="${compile.deprecation}"
                                                optimize="${compile.optimize}"
                                             source="1.6" target="1.6">
                        <classpath refid="DtrApi.classpath"/>
                </javac>

        </target>

        <!-- ==================== Build Target ================================== -->

        <!--

          The "build" target copies all non class files to build directory

        -->

        <target name="build" depends="compile" description="Copies all non Java classes to build directoy">
                <copy todir="${build.home}">
                        <fileset dir="${webapp.home}" excludes="CVS,**/*.class" />
                </copy>
                <copy todir="${build.home}/WEB-INF/classes">
                        <fileset dir="${conf.home}" excludes="CVS,**/*.java" />
                </copy>

                <copy todir="${build.home}/WEB-INF/lib">
                        <filelist refid="apache.libs"/>
                        <filelist refid="DtrApi.libs"/>
                        <mapper type="flatten"/>

                </copy>
        </target>

        <!-- ==================== Archive Target ================================== -->

        <!--

          The "archive" target create a binary archive of all files in build.home

        -->

        <target name="archive" depends="build" description="Create binary archive of all files in dist.home">


                <!-- Create application WAR file -->
                <jar jarfile="${lib.home}/${app.name}.war"
                                basedir="${build.home}" />

        </target>




</project>