On Mon, Nov 26, 2012 at 10:48 AM, Myrna van Lunteren
<[email protected]> wrote:
> On Sun, Nov 25, 2012 at 4:37 PM, Lily Wei <[email protected]> wrote:
>> Hi:
>> When I tried to build the release with the release target, it failed on
>> target 'builduserdocs' with error:
>> BUILD FAILED
>> Execute failed: java.io.IOException: Cannot run pr
>> ogram "ant" (in directory "c:\derby\docs\10.9"): CreateProcess error=2, The
>> syst
>> em cannot find the file specified
>>
>> I can reproduce this with only doing 'ant builduserdocs' from the
>> source root.
>> Please see verbose output attached:
>>
>> Any suggestion on what is wrong with my environment to find executable
>> 'ant' to build builduserdocs?
>>
>>
>> Thanks,
>> Lily
>>
>
> The only suggestion I have is to make sure that your dos command path
> includes the directory for ant. According to this page:
> http://ant.apache.org/manual/Tasks/exec.html
> on windows the <exec> task gets passed on to the windows system. So
> you need to be able to do e.g. ant -version from a dos command, not
> just from cygwin, or other shell tool...
>
> HTH
> Myrna
That same ant manual page also suggests you may not be able to execute
ant.bat directly. So perhaps we've been lucky it works under cygwin
and the target needs to get modified to something like
<exec executable="cmd" dir="${docs.root}>
<arg value="/c"/>
<arg value="ant.bat"/>
<arg value="-p"/>
</exec>
Myrna