Subject: Re: echo is wrong...
From: [email-masked]

7 Apr 1998 08:26:32 -0700
Message-ID: <[email-masked]>
To: [email-masked]

> In the Linux
> 
> [nagyl@piheno nagyl]$ echo  "aaa"|od -c
> 0000000   a   a   a  \n
> 0000004
> 
> In the windows NT bash
> 
> bash-2.01$ echo aaa|od -c
> 0000000   a   a   a  \r  \n
> 0000005
> 
> 
> What the hell is the \r ????? 

In the DOS/Win32 world, text files have CR LF line endings, as opposed to
Unix's LF only.  Since echo generates text, it is simply following the
convention of the operating system and outputting a proper text file.

> I'm running ./configure script (under cygwin bash) and this is failed, because
> the echo isn't compatible with the Unixs echo...
> 
> How to setup (configure etc..) my bash or my echo ?

Actually, I think that configure needs to be fixed, since it aparently
isn't compatible with the DOS/Win32 world.  Failing that, I think that there
is some way to set cygwin so that pipes are created in a binary-only mode,
which will give you Unix style text files.  This is similar to mounting
filesystems with -b, which forces opens to be in binary-only mode.  You
will want to do that as well if you want Unix style text files consistently
throughout.  Note that you will no longer be able to read and write DOS/Win32
text files, so compatibility with the rest of the DOS/Win32 world will be
given up.  Although *most* DOS/Win32 applications can read Unix style text
files, they will almost always write DOS/Win32 style text files.

marcus hall
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".