If your <java> task can takes a bunch of files on the command line, you can
define the <fileset> outside the <java> task (but inside the same <target>
usually), convert it to a (very?) long list of filenames (absolute or
relative) using <pathconvert> stuffed inside a property. Simply de-reference
that property in am <arg> sub-element of your <java> task. It goes a bit
like this:
<target name="atarget">
<fileset if="gg-fileset" dir="somewhere" includes="*.gg" />
<pathconvert refid="gg-fileset" pathsep=" " property="gg-files" />
<java classname="${javaprogram}">
<arg line="${gg-files}" />
</java>
</target>
If your Java program doesn't work that way (ANT uses Javac this way), then
maybe resend your question with a bit more details. Hope this helps, --DD
-----Original Message-----
From: Marc Poulin [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 22, 2002 5:04 PM
To: '[EMAIL PROTECTED]'
Subject: java task over a set of files
We are in the early stages of converting our build process to ant. It has
gone well so far, but I have run into
a bit of a snag. Our Make process uses a java class to process a bunch of
files, namely:
atarget:
$(javaprogram) --arg --anotherarg *.gg
I have been unable to figure out how to "antify" this, since the java task
won't accept fileset nested elements. Is there a way to run a java class
against a bunch of input files in an inexpensive (jvm/processor-wise) way?
Thanks in advance,
Marc
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>