<?xml version='1.0' encoding='ISO-8859-1' ?>
<!-- build_jtb.xml similar to JavaCC build_javacc.xml
     Defines JTB project properties, to be imported by JTB projects
     Marc Mazas - Sopra Group - 05/2009 -->
<project name="jtb_props" default="echo_jtb_props">

  <!-- JTB directories -->
  <dirname property="jtb_proj_dir" file="${ant.file.jtb_props}" />
  <property name="jtb_bin_dir" value="${jtb_proj_dir}/bin" />
  <property name="jtb_jar_dir" value="${jtb_proj_dir}/lib" />
  <property name="jtb_pkg_name" value="EDU.purdue.jtb" />
  <property name="jtb_pkg_dir" value="EDU/purdue/jtb" />
  <property name="jtb_src_dir" value="${jtb_proj_dir}/src/${jtb_pkg_dir}" />

  <!-- JTB files and classes -->
  <property name="jtb_gram" value="jtbgram" />
  <property name="jtb_out" value="jtb.out" />
  <property name="jtb_parser" value="JTBParser" />
  <property name="jtb_main" value="org.javacc.parser.Main" />
  <property name="jtb_tool" value="EDU.purdue.jtb.JTB" />

  <!-- JTB versions -->
  <property name="jtb_last_version" value="1.4.11" />
  <property name="jtb_curr_version" value="1.4.12" />

  <!-- JDK version -->
  <property name="jdk_version" value="1.7" />

  <!-- which JTB jar to use -->
  <!-- bootstrap JTB jar -->
  <property name="jtb_bs_jar" value="${jtb_proj_dir}/lib/jtb132.jar" />
  <!-- last version JTB jar if exists, otherwise bootstrap JTB jar -->
  <property name="jtblv" value="${jtb_jar_dir}/jtb-${jtb_last_version}.jar" />
  <condition property="jtb_last_jar" value="${jtblv}">
    <available file="${jtblv}" />
  </condition>
  <condition property="jtb_last_jar" value="${jtb_bs_jar}">
    <not>
      <available file="${jtb_last_jar}" />
    </not>
  </condition>
  <!-- current version new JTB jar -->
  <property name="jtb_new_jar" value="${jtb_jar_dir}/new_jtb-${jtb_curr_version}.jar" />
  <!-- current version previous JTB jar if exists, otherwise last version JTB jar -->
  <property name="jtb_prev_jar" value="${jtb_jar_dir}/jtb-${jtb_curr_version}.jar" />
  <condition property="jtb_ok_jar" value="${jtb_prev_jar}">
    <available file="${jtb_prev_jar}" />
  </condition>
  <condition property="jtb_ok_jar" value="${jtb_last_jar}">
    <not>
      <available file="${jtb_ok_jar}" />
    </not>
  </condition>

  <!-- echo some JavaCC / JJTree properties -->
  <target name="echo_jtb_props">
    <echo message="jtb_proj_dir=${jtb_proj_dir}" />
    <echo message="jtb_last_version=${jtb_last_version}" />
    <echo message="jtb_curr_version=${jtb_curr_version}" />
    <echo message="jtb_bs_jar=${jtb_bs_jar}" />
    <echo message="jtblv=${jtblv}" />
    <echo message="jtb_last_jar=${jtb_last_jar}" />
    <echo message="jtb_new_jar=${jtb_new_jar}" />
    <echo message="jtb_prev_jar=${jtb_prev_jar}" />
    <echo message="jtb_ok_jar=${jtb_ok_jar}" />
  </target>

</project>
