
<project name="Initialize" default="pre-init">

    <!--
         Determine platform
     -->

    <target name="pre-init">
        <condition property="solaris">
           <os name="SunOS"/>
        </condition>
        <condition property="windows">
           <os family="windows"/>
        </condition>
        <condition property="aix">
           <os name="AIX"/>
        </condition>
        <condition property="linux">
           <os name="Linux"/>
        </condition>
        <condition property="os400">
           <os name="OS/400"/>
        </condition>
        <condition property="hp-ux">
           <os name="HP-UX"/>
        </condition>

        <condition property="platform" value="SunOS">
           <isset property="solaris"/>
        </condition>
        <condition property="platform" value="Win32">
           <and>
	           <isset property="windows"/>
               <not>
                   <isset property="64bit"/>
               </not>
           </and>
        </condition>
        <condition property="platform" value="Win64">
           <and>
	           <isset property="windows"/>
               <isset property="64bit"/>
           </and>
        </condition>
        <condition property="platform" value="Linux">
           <isset property="linux"/>
        </condition>
        <condition property="platform" value="AIX">
           <and>
               <isset property="aix"/>
               <not>
                   <isset property="64bit"/>
               </not>
           </and>
        </condition>
        <condition property="platform" value="AIX64">
           <and>
               <isset property="aix"/>
               <isset property="64bit"/>
           </and>
        </condition>
        <condition property="platform" value="OS400">
           <isset property="os400"/>
        </condition>
        <condition property="platform" value="HP-UX">
            <isset property="hp-ux"/>
        </condition>

        <!--
            Following is needed to distinguish unix variants from OS/400
            since in some cases it is not simply a if="windows" vs. unless="windows".
            Also note that <os family="unix"/> cannot be used since it considers
            OS/400 to be a unix variant. 
         -->
        <condition property="platformIsUnix">
           <or>
              <isset property="solaris"/>
              <isset property="aix"/>
              <isset property="linux"/>
              <isset property="hp-ux"/>
           </or>
        </condition>
		
        <!--
            Load versioning information from version.properties
         -->
        <property file="${dir.properties}/version.properties"/>

    </target>

</project>

