I can not say for sure whether the change t20 and t21 as amended or JAR only in these directories, but on the condition that these directories will be called the same, the following will include all the JAR in the section dirand dir2and create <path>using id="dyna.jars". Please note that this should be refid="dyna.jars", notrefid="${dyna.jars}"
<path id="dyna.jars">
<fileset dir="../../dir1">
<include name="**/*.jar"/>
</fileset>
<fileset dir="../../dir2">
<include name="**/*.jar"/>
</fileset>
</path>
<javac srcdir="${javac.srcdir}" .....>
<classpath refid="dyna.jars" />
</javac>
source
share