This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: sed: 4.1.5 breaks libtool generation


Corinna Vinschen writes:

> Actually, what you describe is clear enough, but since CRLF handling
> isn't done by the Linux version of sed either, you would have the same
> problem on Linux.

Sure, no argument here.  My goal wasn't to prove that Cygwin's sed is doing
something wrong, but rather to confirm that the strange behaviour of the new
version of sed, encountered by some, is due to improper form of line ends, thus
the fault is on the user's, not tool's, side.

> The question here is how did this file get created with CRLF in the
> first place?

It's actually easy -- one just needs to use a Windows editor that's unaware of
alternative forms of line ends and quietly saves the file with CRLFs.

> However, I have a bit of a problem here, either files are read with CRLF
> conversion, as up to 4.1.4.  In that case you can't use sed on binary
> files.  Or sed does not do CRLF conversion as on any other OS.  Then you
> get trouble with plain DOS files.  However, this latter problem can be
> solved by using a filter like dos2unix before feeding the input to sed,
> while the first problem can never be solved if sed always makes a CRLF
> conversion.

If it were my decision, I'd go for the non-converting version, as is now, even
though it means that some users will be required to break certain habits.  After
all, Cygwin emulates Linux, so it figures that the same behaviour of tools
should be expected.

I, for one, learned my lesson, dos2unix'ed all files that are to be processed by
any of the Cygwin's tools and decided to (when in Windows) only use those
editors that respect the appropriate form of line ends.

By the way, kudos to you all gals and guys who keep this respectable machinery
running and evolving.

Best regards.



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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]