delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/06/22/11:12:03

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Fri, 22 Jun 2001 11:06:23 -0400
From: Christopher Faylor <cgf AT redhat DOT com>
To: cygwin AT cygwin DOT com
Cc: David Starks-Browning <starksb AT ebi DOT ac DOT uk>
Subject: Re: Autoconf's suggestion to use bash as /bin/sh
Message-ID: <20010622110623.K13746@redhat.com>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com,
David Starks-Browning <starksb AT ebi DOT ac DOT uk>
References: <3B31D642 DOT 6ACDB3C4 AT yahoo DOT com> <012501c0faf6$7e7d17c0$0201a8c0 AT watch5>
Mime-Version: 1.0
User-Agent: Mutt/1.3.11i
In-Reply-To: <012501c0faf6$7e7d17c0$0201a8c0@watch5>; from cliff@aonix.co.uk on Fri, Jun 22, 2001 at 09:36:18AM +0100

On Fri, Jun 22, 2001 at 09:36:18AM +0100, Cliff Hones wrote:
>Earnie Boyd wrote:
>> I suppose Cliff Hones had a question and wasn't just posting to be
>> posting and I assume the hidden question to be "Why does Cygwin not use
>> bash as sh?" and that is covered in the FAQ.  However, once upon a time
>> a long time ago Cygwin did use bash as sh.  It was discovered that
>> scripts and software builds would happen more quickly if ash was used as
>> sh.  So the next release of Cygwin after the discovery included ash as
>> sh.  This doesn't prevent you from using it now, simply `cp
>> /bin/bash.exe /bin/sh.exe' and you'll be compliant with the autoconf
>> suggestion.  However, you would have slowed down the functioning of
>> Cygwin scripts and package builds.
>
>I didn't really mean to be asking a hidden question.  Indeed I have
>wondered why Cygwin uses ash for sh, and many thanks for the
>explanation.  BTW, I couldn't find it in the FAQ - and I've just
>looked at all occurrences of bash (of which there are many!).
>
>My main reason for posting was simply the conflicting advice; given
>the frequent comments of "you shouldn't suggest that" when people
>raise the issue of copying or linking bash to sh, it seemed odd that a
>Red Hat document should be doing just that.
>
>And finally, maybe it would help if the "don't do that"
>messages gave a reason why it shouldn't be done,

Did you read Earnie's response?  He gave reasons.

What you're really asking is:

"I just installed cygwin and notice that it has a /bin/sh and a
/bin/bash.  I think I'll just copy /bin/bash to /bin/sh.  Why won't
you let me do this?"

You have the ability to do anything you want with cygwin.  However,
surely it makes sense that we must have had SOME reason for doing this
and if you decide to make your installation nonstandard then you should
not necessarily expect support for what you're doing from people who
decided to do things in such an incredibly incomprehensible way.

Btw, let me clear up a misconception.  The fact that a project exists on
sources.redhat.com does not mean that it is a Red Hat project.  The
reference that you pointed to contains words written by four people, two
of whom are Red Hat employees.  That doesn't make it an official Red Hat
document.

However, even if it was a Red Hat project, it shouldn't be too
surprising that a large company could produce conflicting documents.

Hmm.  I just looked at the words in question and they seem pretty benign
to me:

Bourne shell 
Cygwin provides a port of ash which is smaller and faster than bash, but
sometimes rejects arcane Bourne shell scripts.  If you can stand to
sacrifice a little speed, it is worth copying the supplied bash.exe to
`/bin/sh.exe' to forestall any such problems

The words actually describe the reason for ash and describe the
consequences of overwriting /bin/sh.

We usually tell people "don't do that" when they copy /bin/bash over
/bin/sh because of a bug in /bin/sh.  The hoped for method of dealing
with bugs is that someone reports them (and hopefully provides a patch).
Just silently working around the problem means that random people will
trip over it and the problem will exist until someone decides to report
it.

Anyway, I just searched the FAQ for words about this, and I didn't
find any either.  Chuck, could you add some words, please?

cgf

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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