samples/libs/build.xml
changeset 21 0aee50e597da
parent 18 1e82ffa1391b
child 79 76b5dfab3745
     1.1 --- a/samples/libs/build.xml	Sat Jun 14 09:51:04 2008 +0200
     1.2 +++ b/samples/libs/build.xml	Sat Jun 14 09:51:05 2008 +0200
     1.3 @@ -6,8 +6,8 @@
     1.4      
     1.5      <target name="libraries">
     1.6          <antcall target="-library">
     1.7 -            <param name="library" value="junit-4.1"/>
     1.8 -            <param name="url" value="junit"/>
     1.9 +            <param name="library" value="junit-4.4"/>
    1.10 +            <param name="url" value="http://switch.dl.sourceforge.net/sourceforge/junit/junit-4.4.jar"/>
    1.11          </antcall>
    1.12      </target>
    1.13      
    1.14 @@ -17,16 +17,18 @@
    1.15          <fail message="You need to specify library name" unless="library"/>
    1.16          <fail message="You need to specify url" unless="url"/>
    1.17          
    1.18 -        <echo message="Checking for dist/${library}.jar"/>
    1.19 -        <available file="dist/${library}.jar" property="library.available"/>
    1.20 +        <property name="library.jar" location="dist/${library}.jar"/>
    1.21 +        
    1.22 +        <echo message="Checking for ${library.jar}"/>
    1.23 +        <available file="${library.jar}" property="library.available"/>
    1.24      </target>
    1.25      <target name="-library" depends="-library-check" unless="library.available">
    1.26          <mkdir dir="dist"/>
    1.27 -        <get dest="dist/${library}" src="${url}"/>
    1.28 +        <get dest="${library.jar}" src="${url}"/>
    1.29          
    1.30          <fail message="Now the library ${library} should be downloaded">
    1.31              <condition>
    1.32 -                <available file="dist/${library}.jar"/>
    1.33 +                <not><available file="${library.jar}"/></not>
    1.34              </condition>
    1.35          </fail>
    1.36      </target>