ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam Murdoch" <adammurd...@yahoo.com>
Subject RE: trying to convert to 1.2...
Date Thu, 26 Oct 2000 11:57:15 GMT

Hi,

This is usually a problem with the PATH environment variable.  The 1.3 JVM
resolves the executable name relative to its' working directory (ie the one
that ant is running in), not relative to the target directory (ie the one
given in the dir attribute of <exec>).  So, if 'clean.bat' is not in the
directory you're running ant from, then you'll need to add it to your PATH,
or alternatively, use a relative path to it in command="..." or
executable="...".


Adam

> -----Original Message-----
> From: james@livemedia.com [mailto:james@livemedia.com]
> Sent: Thursday, 26 October 2000 11:28 AM
> To: ant-user@jakarta.apache.org
> Subject: trying to convert to 1.2...
>
>
> this tag:
>
> <exec dir="${SRC}/${FRAMEWORK}/metadata/123"^M
>         command="clean.bat"^M
>         output="${SRC}/${FRAMEWORK}/metadata/123/clean.out"^M
> />^M
>
> runs under 1.1, but under 1.2  produces the following during the build:
>
> metadata:
>      [exec] The command attribute is deprecated. Please use the executable
> attri
> bute and nested arg elements.
>
> BUILD FAILED
>
> L:\src\comp\1.0\src\build2.xml:644: Execute failed:
> java.io.IOException: Cr
> eateProcess: clean.bat error=2
> java.io.IOException: CreateProcess: clean.bat error=2
>         at java.lang.Win32Process.create(Native Method)
>         at java.lang.Win32Process.<init>(Win32Process.java:66)
>         at java.lang.Runtime.execInternal(Native Method)
>         at java.lang.Runtime.exec(Runtime.java:551)
>         at java.lang.reflect.Method.invoke(Native Method)
>         at
> org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Exec
> ute.java:390)
>         at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:247)
>         at
> org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:213)
>         at
> org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:154)
>         at org.apache.tools.ant.Target.execute(Target.java:142)
>         at org.apache.tools.ant.Project.runTarget(Project.java:818)
>         at org.apache.tools.ant.Project.executeTarget(Project.java:532)
>         at org.apache.tools.ant.Project.executeTargets(Project.java:506)
>         at org.apache.tools.ant.Main.runBuild(Main.java:420)
>         at org.apache.tools.ant.Main.main(Main.java:149)
>
>
> any clues are appreciated.
>
> thanks,
> james@livemedia.com


_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


Mime
View raw message