delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/09/19/17:47:37

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-10.6 required=5.0 tests=AWL,BAYES_00,KHOP_PGP_SIGNED,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS
X-Spam-Check-By: sourceware.org
Message-ID: <505A3D52.2020800@redhat.com>
Date: Wed, 19 Sep 2012 15:46:58 -0600
From: Eric Blake <eblake AT redhat DOT com>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120828 Thunderbird/15.0
MIME-Version: 1.0
To: cygwin AT cygwin DOT com, rfhaney AT yahoo DOT com
Subject: Re: bash output: ./configure: line 16: $'\r': command not found
References: <1348088813 DOT 66748 DOT YahooMailClassic AT web111515 DOT mail DOT gq1 DOT yahoo DOT com>
In-Reply-To: <1348088813.66748.YahooMailClassic@web111515.mail.gq1.yahoo.com>
OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

--------------enigBC1A798B9F0406C155ECFBBB
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On 09/19/2012 03:06 PM, Richard Haney wrote:
> Generally, there are lots and lots of script files for every build.  That=
 means my builds could be crashing right and left all over the place if bas=
h does not always ignore carriage returns when it is supposed to.  So I nee=
d for bash to be able to always ignore carriage returns

Then ask bash to do that.  It does not ignore carriage returns by
default (because it does not ignore carriage returns on Linux by
default), but the thing about defaults is that they can be changed.

> The second problem is that I can find no documentation for the bash '-o i=
gncr' command-line option.

Patches welcome; but here's the cygwin-specific documentation that DOES
mention it:

http://cygwin.com/ml/cygwin-announce/2011-02/msg00027.html
/usr/share/doc/Cygwin/bash.README

which includes these suggestions:

4c. To affect all scripts, export the environment variable BASH_ENV,
pointing to a file that sets the shell option as desired.  Bash will
source this file on startup for every script.
4d. Added in the bash-3.2-2 release: export the environment variable
SHELLOPTS with igncr included in it.  It is read-only from within bash,
but you can set it before invoking bash; once in bash, it auto-tracks
the current state of 'set -o igncr'.  If exported, then all bash child
processes inherit the same option settings; with the exception added in
3.2.9-11 that certain interactive options are not inherited in
non-interactive use.

--=20
Eric Blake   eblake AT redhat DOT com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


--------------enigBC1A798B9F0406C155ECFBBB
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Public key at http://people.redhat.com/eblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iQEcBAEBCAAGBQJQWj1SAAoJEKeha0olJ0NqfckH/2tbAirqz3SCq5bbw+x8ah22
NL1Pvws2RTY/JZEq/2JDO4MSZr+//Mw++jtzAx0T+R5Jj35hk9ai886KFS/e3SS6
Qkz9ylpmjpROSU3zJgq3LZ7/ZTgQN5weFOwvPaBk+IIQMPWzh4OhSCgdf2jmSWOG
DvbNnEWw1g8YzUCccCBfgN6woNexr6bKs2I6hd4R/QR43GCVAqo9JeGuiuUhxNoJ
4h+YedI0fMzttHxoBPUPbmBU8Xe4Fq2s+/dh20y4zoJhB2kijwNgHkz+wQSY0LOR
PdHHwBSB981/q3WgvfTmPBwPU9d6AGz2JdS509tVlA+xjMxlRWGAnkSn1p3g5B8=
=GB3E
-----END PGP SIGNATURE-----

--------------enigBC1A798B9F0406C155ECFBBB--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019