All Downloads are FREE. Search and download functionalities are using the official Maven repository.

templates.commands.build.xml Maven / Gradle / Ivy

The newest version!
<?xml version="1.0" encoding="UTF-8"?>
<!-- 
  This is the Ant build file for building the GemFire Command Example. 
  It was tested with Ant 1.6.2, but should work (possibly with slight modifications) on any version of Ant.

  How to build:
    Preform basic ant setup: 
      confirm javac is in your PATH
      set JAVA_HOME to match
      confirm ant is in your PATH**
    Run the actual targets:
      ant clean build jar
  **This build file is incompatable with versions of ant compiled using gcj, instead of calling "ant build" instead use "classic-ant build"
-->

<project default="usage" name="gemfireCommandExample">
  <description>Builds GemFire Commad Example</description>

  <target depends="usage" name="help"/> 

  <target name="usage">
    <description>Prints information about what can be built</description>


    <echo>
targets:
  clean                Deletes the &#36;&#123;output.dir&#125;
  build                Builds all GemFire template code
  jar                  Builds a jar of the GemFire template code
  usage (or help)      Prints this help information

Command Line Defines:
  -Dgemfire.build.dir=&lt;path&gt;  Specify where output files should be stored 
                              Default is the current directory.
  -Dgemfire.lib=&lt;path&gt;        Specify the path to the gemfire lib directory
                              Default is "../../lib" 
    </echo>
  </target>

  <target depends="" name="-init"> 
    <property name="gemfire.build.dir" location="${basedir}/build-artifacts"/>
    <property name="gemfire.lib" location="../../lib"/>
    <property name="gemfire.template.jar" 
      location="${gemfire.build.dir}/gfcommands.jar"/>
  </target>

  <target depends="-init" name="clean"> 
    <description>Deletes the artifacts from a previous build.</description>
    <delete dir="${gemfire.build.dir}" quiet="true"/>
  </target>

  <target depends="-init" name="build"> 
    <mkdir dir="${gemfire.build.dir}"/>
    <javac debug="on" deprecation="true" destdir="${gemfire.build.dir}" 
      includeAntRuntime="false" nowarn="off" optimize="off" 
      srcdir="${basedir}" verbose="off">
      <classpath>
        <pathelement location="${gemfire.lib}/gemfire.jar"/>
        <pathelement location="${gemfire.lib}/spring-shell-1.0.0.RELEASE.jar"/>
        <pathelement location="jsch-0.1.49.jar"/>
      </classpath>
      <include name="**/*.java"/>
    </javac>
  </target>

  <target depends="-init, build" name="jar"> 
    <jar destfile="${gemfire.template.jar}">
      <fileset dir="${gemfire.build.dir}" includes="templates/commands/**/*.class"/>
    </jar>
  </target>
</project>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy