--- [EMAIL PROTECTED] wrote:
> Appears that if I call Ant from within a makefile using a batchfile, I
> don't get any return code back
Yeah you do, you just get a 0 instead of a 1, but it doesn't have anything
to do with calling it from make.
> ie I would have to basically copy all of the ant batchfile
> into the makefile to be able to check the return code.
>
> Is this true?
Nope -- copying the entire ant.bat into your makefile wouldn't change
anything, because a batch file (like a shell-script) will exit with the
status of whatever line it executed last (except with batch files, even if
that line is a "rem" it still counts -- which is incredibly stoopid :),
and in ant.bat, there's all kinds of lines after the running of Ant.
For kicks, do this:
- cd to your $ANT_HOME/bin dir
- copy ant.bat to funky.bat
- bring funky.bat up in an editor and delete everything after the
java command line that follows the ":runAnt" line.
Now run the following:
funky -f bogus.xml || echo Ant exited 1
ant -f bogus.xml || echo Ant exited 1
Note that 'funky' does the right thing, but 'ant' doesn't.
> Does anyone have any kind of workaround, apart from the build
> listener?
Other than getting rid of everything after the "$JAVACMD ..." line? --
install cygwin onto your PC so you can run 'ant' instead of 'ant.bat' :)
Diane
=====
([EMAIL PROTECTED])
__________________________________________________
Do You Yahoo!?
Yahoo! Sports - live college hoops coverage
http://sports.yahoo.com/
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>