<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project >
<project name="JaxbBooleanGetterPlugin" default="dist" basedir=".">
  <!--
  <tstamp/>
  -->
  <property name="DSTAMP" value="2.1.3" />
  <property name="src.dir" location="src" />
  <property name="etc.dir" location="etc" />
  <property name="target.dir" location="target" />
  <property name="target.classes.dir" location="${target.dir}/classes" />
  <property name="dist.dir" location="dist" />
  <property name="jaxb.version" value="2.1.3" />
  <property name="dist.jar.file" value="${dist.dir}/fixbooleangetter.jar"/>
  <property name="jaxb-ri.dist.lib.dir" location="lib" />
  <property name="hchar.deploy.todir" location="${jaxb-ri.dist.lib.dir}"/>

  <path id="jaxb-xjc.lib.classpath">
  	<fileset dir="${jaxb-ri.dist.lib.dir}" includes="jaxb-xjc.jar" />
  </path>
	
  <path id="lib.classpath">
  	<fileset dir="lib" includes="*.jar" />
  </path>
	
  <!-- This rebuilds the world. -->
  <!--
  <target depends="clean,compile,jar,deploy-hchar" name="full" />
  -->
  <target depends="clean,compile,jar" name="dist" />

  <!-- Destroys all generated code and compiled files. -->
  <target name="clean">
    <delete dir="${target.dir}"/>
    <delete dir="${dist.dir}"/>
  </target>

  <!-- Creates the directory structure which holds the generated code
       and compiled classes. -->
  <target name="prepare" depends="clean">
    <mkdir dir="${target.dir}"/>
    <mkdir dir="${target.classes.dir}"/>
    <mkdir dir="${dist.dir}"/>
  </target>

  <path id="compile.classpath">
    <path refid="jaxb-xjc.lib.classpath"/>
    <path refid="lib.classpath"/>
    <pathelement path="${target.classes.dir}"/>
  </path>

  <target name="compile" depends="prepare">
    <javac compiler="javac1.5"
    	   destdir="${target.classes.dir}"
           debug="true"
           classpathref="compile.classpath">
    	<src path="${src.dir}" />
  	</javac>
  </target>
	
  <!-- Distribution related properties -->
  <target name="jar">
    <jar destfile="${dist.jar.file}">
      	<fileset dir="${target.classes.dir}" includes="**/*.class"/>
      	<fileset dir="${etc.dir}" includes="com.sun.tools.xjc.Plugin" />
    	<metainf dir="${src.dir}/META-INF" />
    </jar>
  </target>  

  <target name="jar-maven">
	<property name="maven.dist.jar.file" value="maven-jaxbbooleangetter-plugin-${DSTAMP}.jar" />
	<jar destfile="${maven.dist.jar.file}">
		<fileset dir="${dist.dir}" />
		<fileset dir="." includes="pom.xml"/>
	</jar>
  </target>

</project>
