ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b <>
Subject Deriving something from <srcfile/> from within <apply>
Date Thu, 06 Apr 2006 15:26:57 GMT
I'm trying to code up an <APPLY> in ANT.

I need to run a utility which takes 2 parameters, 1) a source file name 
(<srcfile/>), and 2) something derived from the source file name (<arg 
value="...">).   The output of this program is a file, whose name is 
derived from the source file name (<targetfile/>, which is used for 
timestamp checking.

My problem is deriving the 2nd parameter.  I can't use a <mapper> 
because it is already in use to handle <srcfile/> and <targetfile/>.

Does <srcfile/> ever get put into a property that I can access?  Then it 
would be simple.  I can add <arg value="blahblahblah${srcfile}">

Otherwise, I think I am stuck.   Although I could alter the utility to 
accept 'blahblahblah' as a parameter and derive parm 2 myself in the 
utility, I would rather not do that.  I'd just as soon go back to Make.

Also, ant apprently won't allow me to specify <srcfile/> twice.

loose Example of what I'm tyring...

         <apply executable="utility" relative="true">
             <arg value="blah${srcfile}/>    ****problem here****
             <fileset refid="sourceFiles"/>
             <mapper type="glob" from="*.in" to="*.in.done"/>

Any hints?

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message