public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: "Matt D." <matt@codespunk.com>
To: cygwin@cygwin.com
Subject: Re: Bug with Cygwin's 'quilt' is actually in 'patch'
Date: Thu, 20 Jun 2013 07:44:00 -0000	[thread overview]
Message-ID: <51C2A293.8020805@codespunk.com> (raw)
In-Reply-To: <20130620054715.GC5122@ednor.casa.cgf.cx>

I'm building from Linux source from the X2Go git repository. The patches 
are being applied downstream to the last base nx libraries provided by 
NoMachine. It can't be helped if the original source has CRLF in this case.

I understand that Cygwin is trying to emulate Linux here, but I don't 
believe that is the appropriate response regarding tools like 'patch' 
which should not have this kind of limitation. The fact that it thinks:

 > \r\n <> \r\n

but..

 > \r\n == \n

As I mentioned previously, patch does NOT have this issue on Linux using 
the EXACT SAME test case.

This is definitely a bug.


On 6/20/2013 1:47 AM, Christopher Faylor wrote:
> On Wed, Jun 19, 2013 at 11:31:48PM -0400, Matt D. wrote:
>> I've been looking further into this and it appears as though the problem
>> is in 'patch' not 'quilt'. quilt is actually a collection of bash
>> scripts and calls patch to do the actual patching.
>>
>> Using the same example I provided earlier in the thread, the same error
>> occurs when calling patch directly:
>>
>> $ patch Imakefile patches/test.patch
>>
>> Running dos2unix on test.patch will allow the patch to apply
>> successfully. However, this is WRONG. Imakefile and the initially
>> created test.patch both use CRLF line endings. The patch should
>> definitely NOT apply by introducing actual disparity.
>>
>> To summarize, the patch to Imakefile (CRLF) will apply if it is
>> converted to LF line endings. Using the '--binary' switch seems to be a
>> workaround for this issue.
>
> Sorry but we're emulating Linux here.  You shouldn't have CRLF endings
> on your text file if you want the tools to work reliably.
>
> cgf
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>
>
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

  reply	other threads:[~2013-06-20  6:35 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-18  5:37 Bug with Cygwin's 'quilt' Matt D.
2013-06-18  5:47 ` Matt D.
2013-06-20  5:47   ` Bug with Cygwin's 'quilt' is actually in 'patch' Matt D.
2013-06-20  6:35     ` Christopher Faylor
2013-06-20  7:44       ` Matt D. [this message]
2013-06-20  8:22     ` Corinna Vinschen
2013-06-21 12:15       ` Corinna Vinschen
2013-06-21 17:06         ` Matt D.
2013-07-03  3:05 Peter B.
2013-07-03 12:33 ` Corinna Vinschen
2013-07-03 13:07   ` Peter B.
2013-07-03 13:30     ` Corinna Vinschen
2013-07-03 15:35       ` Peter B.

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51C2A293.8020805@codespunk.com \
    --to=matt@codespunk.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).