You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by bu...@apache.org on 2003/05/28 01:48:42 UTC
DO NOT REPLY [Bug 20282] New: -
before a is ignored by targets
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20282>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20282
<path> before a <property> is ignored by targets
Summary: <path> before a <property> is ignored by targets
Product: Ant
Version: 1.5.3
Platform: All
URL: http://www.xdweb.net/~dibblego/resume
OS/Version: Other
Status: NEW
Severity: Normal
Priority: Other
Component: Core
AssignedTo: dev@ant.apache.org
ReportedBy: tonymorr@au1.ibm.com
CC: tonymorr@au1.ibm.com
I have the following:
<project>
<target name="blah">
<property name="src.dir" value="src" description="Source directory"/>
<path id="project.class.path>
<pathelement path="${lib.dir}"/>
</path>
<javac ...>
<classpath refid="project.class.path"/>
</javac>
</target>
The CLASSPATH is ignored. I tested this by having the project have a dependency
in the lib directory and watched the build fail because of it.
After some heartache, I found the following workaround ...
Change the order of the <path> and <property>:
<project>
<target name="blah">
<path id="project.class.path>
<pathelement path="${lib.dir}"/>
</path>
<property name="src.dir" value="src" description="Source directory"/>
<javac ...>
<classpath refid="project.class.path"/>
</javac>
</target>
Apologies if this is a duplicate bug or a misuse of Ant. I searched everywhere
for an explanation.