You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by John Hempe <jh...@north.com> on 2000/11/16 05:45:32 UTC

Debugging references

So if I define something like:

<path id="compile.class.path">
  <pathelement location="${something}/classes"/>
  <pathelement location="${something.else}/classes"/>
</path> 

How can I "echo" what "compile.class.path" gets set to?  How can I see it at
runtime?  I am running Ant 1.2, and when I try to refer to this construct in
a later "javac" task (for instance), I get some path that has nothing to do
with what I've set up.  

Back when I was just using a variable ${compile.classpath} everything was
working fine, even though it looked ugly and I figured the reference way
would be more extensible. 

I tried <echo message="${compile.class.path}"> but that doesn't work, so
there must be another way to dump references. . .but even running "ant
-debug" doesn't seem to dump the reference.

--John



Re: Debugging references

Posted by Stefan Bodewig <bo...@bost.de>.
John Hempe <jh...@north.com> wrote:

> So if I define something like:
> 
> <path id="compile.class.path">
>   <pathelement location="${something}/classes"/>
>   <pathelement location="${something.else}/classes"/>
> </path> 
> 
> How can I "echo" what "compile.class.path" gets set to?  How can I
> see it at runtime?

<snip/>

> I tried <echo message="${compile.class.path}"> but that doesn't
> work,

Assign it to a property in between:

<property name="compile.class.path" refid="compile.class.path" />
<echo message="${compile.class.path}">

ugly but it should work.

Stefan