Thanks a lot Diane. The logic you provided worked. I am using 1.4.1 and
soon will migrate to 1.5 Alpha.
To give an idea of what I am doing is
<target name="chkTMFile" depends="jar">
<available property="isAvailable" file="${COMP_TM.JAR}"/>
</target>
<target name="chkPAYFile" depends="jar">
<available property="isAvailable" file="${COMP_PAY.JAR}"/>
</target>
<target name="chkUSERFile" depends="jar">
<available property="isAvailable" file="${COMP_USER.JAR}"/>
</target>
<target name="chkREPORTFile" depends="jar">
<available property="isAvailable" file="${COMP_REPORT.JAR}"/>
</target>
<target name="chkBILLFile" depends="jar">
<available property="isAvailable" file="${COMP_BILL.JAR}"/>
</target>
<target name="chkBSPFile" depends="jar">
<available property="isAvailable" file="${COMP_BSP.JAR}"/>
</target>
<target name="chkCFFile" depends="jar">
<available property="isAvailable" file="${COMP_CF.JAR}"/>
</target>
<target name="chkSHAREDFile" depends="jar">
<available property="isAvailable" file="${COMP_SHARED.JAR}"/>
</target>
<target name="copy">
<antcall target="copyTMjars" >
<param name="file" value="${COMP_TM.JAR}"/>
</antcall>
<antcall target="copyPAYjars" >
<param name="file" value="${COMP_PAY.JAR}"/>
</antcall>
<antcall target="copyUSERjars" >
<param name="file" value="${COMP_USER.JAR}"/>
</antcall>
<antcall target="copyREPORTjars" >
<param name="file" value="${COMP_REPORT.JAR}"/>
</antcall>
<antcall target="copyBILLjars" >
<param name="file" value="${COMP_BILL.JAR}"/>
</antcall>
<antcall target="copyBSPjars" >
<param name="file" value="${COMP_BSP.JAR}"/>
</antcall>
<antcall target="copyCFjars" >
<param name="file" value="${COMP_CF.JAR}"/>
</antcall>
<antcall target="copySHAREDjars" >
<param name="file" value="${COMP_SHARED.JAR}"/>
</antcall>
</target>
<target name="copyTMjars" depends="copyIfTMAvailable,copyIfTMNotAvailable" />
<target name="copyPAYjars" depends="copyIfPAYAvailable,copyIfPAYNotAvailable"/>
<target name="copyUSERjars" depends="copyIfUSERAvailable,copyIfUSERNotAvailable"/>
<target name="copyREPORTjars"
depends="copyIfREPORTAvailable,copyIfREPORTNotAvailable"/>
<target name="copyBILLjars" depends="copyIfBILLAvailable,copyIfBILLNotAvailable"/>
<target name="copyBSPjars" depends="copyIfBSPAvailable,copyIfBSPNotAvailable"/>
<target name="copyCFjars" depends="copyIfCFAvailable,copyIfCFNotAvailable"/>
<target name="copySHAREDjars"
depends="copyIfSHAREDAvailable,copyIfSHAREDNotAvailable"/>
<target name="copyIfTMAvailable" depends="chkTMFile" if="isAvailable">
<copy file="${COMP_TM.JAR}" todir="${CODE_BASE}../" />
</target>
<target name="copyIfTMNotAvailable" depends="chkTMFile" unless="isAvailable">
<copy file="${TM_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfPAYAvailable" depends="chkPAYFile" if="isAvailable">
<copy file="${COMP_PAY.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfPAYNotAvailable" depends="chkPAYFile" unless="isAvailable">
<copy file="${PAY_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfUSERAvailable" depends="chkUSERFile" if="isAvailable">
<copy file="${COMP_USER.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfUSERNotAvailable" depends="chkUSERFile" unless="isAvailable">
<copy file="${USER_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfREPORTAvailable" depends="chkREPORTFile" if="isAvailable">
<copy file="${COMP_REPORT.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfREPORTNotAvailable" depends="chkREPORTFile"
unless="isAvailable">
<copy file="${REPORT_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfBILLAvailable" depends="chkBILLFile" if="isAvailable">
<copy file="${COMP_BILL.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfBILLNotAvailable" depends="chkBILLFile" unless="isAvailable">
<copy file="${BILL_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfBSPAvailable" depends="chkBSPFile" if="isAvailable">
<copy file="${COMP_BSP.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfBSPNotAvailable" depends="chkBSPFile" unless="isAvailable">
<copy file="${BSP_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfCFAvailable" depends="chkCFFile" if="isAvailable">
<copy file="${COMP_CF.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfCFNotAvailable" depends="chkCFFile" unless="isAvailable">
<copy file="${CF_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfSHAREDAvailable" depends="chkSHAREDFile" if="isAvailable">
<copy file="${COMP_SHARED.JAR}" todir="${CODE_BASE}../"/>
</target>
<target name="copyIfSHAREDNotAvailable" depends="chkSHAREDFile"
unless="isAvailable">
<copy file="${SHARED_JAR_PATH}" todir="${CODE_BASE}../"/>
</target>
Thx
Kailash
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>