ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jacob Kjome <>
Subject Re: <patch> task on win32?
Date Tue, 25 Nov 2003 04:30:26 GMT

Any comment on this?  It seems like a bug and, if so, should probably be 
fixed before the next 1.6 beta.


At 11:19 PM 11/22/2003 -0600, you wrote:

>Hmm....  I just got it to work with the gnuwin32 library.  However, it 
>seems to me that the fact that it didn't work the original way I had it is 
>a bug.  Here is what I did to make it work...
>I changed this:
><patch patchfile="ant-patch.txt"/>
>to this:
><patch dir="${basedir}/src" patchfile="ant-patch.txt" strip="1"/>
>However, shouldn't the following be equivalent (which, according to the 
>docs, is equivalent to the original basic syntax.)?
><patch dir="${basedir}" patchfile="ant-patch.txt"/>
>See docs at:
>But that doesn't work.  Why do I have to change into the "src" dir, and 
>then strip the "src/" part of 
>"src/etc/testcases/taskdefs/typedef.xml"?  Am I missing something?  How is 
>this not equivalent to the original basic syntax?
>Can someone confirm whether or not this is a bug?
>At 09:35 PM 11/22/2003 -0600, you wrote:
>>Has anyone gotten the <patch> task to work for them on Win32?  That is, 
>>without installing cygwin.  I tried some native patch programs linked to here:
>>The most up to date is the one here at the gnuwin32 project:
>>However, all I ever get is...
>>     [patch] can't find file to patch at input line 8
>>     [patch] Perhaps you should have used the -p or --strip option?
>>     [patch] The text leading up to this was:
>>     [patch] --------------------------
>>     [patch] |Index: src/etc/testcases/taskdefs/typedef.xml
>>     [patch] 
>> |===================================================================
>>     [patch] |RCS file: 
>> /home/cvs/ant/src/etc/testcases/taskdefs/typedef.xml,v
>>     [patch] |retrieving revision 1.2
>>     [patch] |diff -u -r1.2 typedef.xml
>>     [patch] |--- src/etc/testcases/taskdefs/typedef.xml 21 Jul 2003 
>> 10:10:06 -0000      1.2
>>     [patch] |+++ src/etc/testcases/taskdefs/typedef.xml 18 Nov 2003 
>> 15:11:07 -0000
>>     [patch] --------------------------
>>     [patch] File to patch:
>>     [patch] Skip this patch? [y]
>>     [patch] Skipping patch.
>>     [patch] 1 out of 1 hunk ignored
>>I have the patch file in the correct relative location (the root of the 
>>build for Ant) along with a patch-apply.xml build file....
>><project default="patch" basedir=".">
>>     <target name="patch">
>>         <patch patchfile="ant-patch.txt"/>
>>     </target>
>>Any hints?  Is there any port for patch on win32 that works with the 
>><patch> task?  BTW, this was tested with the latest Ant 1.6 Branch.
>>To unsubscribe, e-mail:
>>For additional commands, e-mail:
>To unsubscribe, e-mail:
>For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message