ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zacke <>
Subject Path problems
Date Fri, 10 Nov 2000 15:18:18 GMT

I would like to add a path to my source path if I don't find a specific jar 
I would like to do something like this:

<-- Add the sourcepath to moduleA if moduleA.jar is missing.
<path id="source.path">
  <pathelement location="${root.dir}/moduleA/src" unless="moduleA" />

<!-- Check to see what dependencies jar files are available -->
<target name="check_for_dependencies">
  <available property="moduleA" file="${root.dir}/moduleA/distr/moduleA.jar" 

<!-- Compiles the source code -->
<target name="compile" depends="prepare,check_for_dependencies">
  <javac srcdir="${src}" destdir="${build}">
    <classpath refid="class.path" />
    <src refid="source.path" />

But this will not work because "unless" will not work in "pathelement".
Any suggestions ?


View raw message