ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rolf Schumacher <Rolf.Schumac...@hamburg.de>
Subject How does >property< function?
Date Tue, 08 Oct 2002 17:37:33 GMT
I thought I've understood the >property< keyword.
But what might be the difference in running ant on the following
---
<?xml version="1.0" encoding="UTF-8"?>
<project basedir="." default="all" name="helloWorld">
    <target name="init">
        <property name="classes" value="/rolf/Java/build/WEB-INF/classes"/>
    </target>
   
    <classfileset id="cfs" dir="${classes}">
    <!-- classfileset id="cfs" dir="/rolf/Java/build/WEB-INF/classes" -->
        <include name="de/toolsprofi/rsc/Log.class"/>
    </classfileset>
   
    <target name="all" depends="init">
        <jar compress="true" jarfile="/Windows/Temp/helloWorld.jar">
            <fileset refid="cfs"/>
        </jar>
    </target>

</project>
---
and with the classfileset lines switched?

Run as shown leads to an BUILD FAILED with a hint that I do not understand.
Run with the explicit dir="/rolf..." functions as I think it should.

Any point I missed?

Rolf

Appendix: the error message copied from dos window
---
C:\rolf\Java\src\de\toolsprofi\helloWorld>ant
Buildfile: build.xml

init:

all:

BUILD FAILED
file:C:/rolf/Java/src/de/toolsprofi/helloWorld/build.xml:12: 
C:\rolf\Java\src\de
\toolsprofi\helloWorld\${classes} not found.

Total time: 1 second
C:\rolf\Java\src\de\toolsprofi\helloWorld>
---
the good message with switched dir-specs
---
C:\rolf\Java\src\de\toolsprofi\helloWorld>ant
Buildfile: build.xml

init:

all:

BUILD SUCCESSFUL
Total time: 1 second
C:\rolf\Java\src\de\toolsprofi\helloWorld>
---


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message