Hi there I am using Apache Ant to build a Java project, and need a bit of help with regard to being able to use "if" statements from within the build.xml file.
Basically I have defined a few targets of which one of the targets does not get executed unless I pass in an argument, the argument passing from the command line works well using the <arg line= " -a "....
but the problem is I have other targets defined which are required to be compile even for the <arg line= " -a ".... compile option . and these other targeds have explicit <exclude> and <include> definitions and I want to chose to <exclude> a few of the <include> if the -a option is passed in
eg
<target name= A>
bla
bla
<include> drictry_c/*.java </include>
...
<target name = B dependon = A>
bla
bla
<arg line=" -a ">
...
what I would liek to do is have target A run as normal and include directory_c durin for normal invokation
$: ant A
and when I invoke ant with
$: ant -a B
(since it depends on A I want Ant to use Target A's definitions but instead of including it should exclude directory_c ) in cases tagret B or any other target is called with arg "-a"
any Ant Guru's willing to help me out
cheers
Basically I have defined a few targets of which one of the targets does not get executed unless I pass in an argument, the argument passing from the command line works well using the <arg line= " -a "....
but the problem is I have other targets defined which are required to be compile even for the <arg line= " -a ".... compile option . and these other targeds have explicit <exclude> and <include> definitions and I want to chose to <exclude> a few of the <include> if the -a option is passed in
eg
<target name= A>
bla
bla
<include> drictry_c/*.java </include>
...
<target name = B dependon = A>
bla
bla
<arg line=" -a ">
...
what I would liek to do is have target A run as normal and include directory_c durin for normal invokation
$: ant A
and when I invoke ant with
$: ant -a B
(since it depends on A I want Ant to use Target A's definitions but instead of including it should exclude directory_c ) in cases tagret B or any other target is called with arg "-a"
any Ant Guru's willing to help me out
cheers
