This is the mail archive of the egcs@egcs.cygnus.com mailing list for the EGCS project. See the EGCS home page for more information.
(Forgot to send this to the list as well as Zack)
- To: Zack Weinberg <zack@rabi.columbia.edu>
- Subject: Re: Style question $()
- From: Donn Terry <donn@verinet.com>
- Date: Sat, 13 Feb 1999 18:44:10 -0700
- References: <199902140121.UAA14306@blastula.phys.columbia.edu>
Zack Weinberg wrote: > On Sat, 13 Feb 1999 18:08:47 -0700, Donn Terry wrote: > > > >Bottom line... If we can insist on a POSIX shell (probably using > >the "(" in case/esac option since we're batting 2/2 on having > >that bug), then we have a fairly simple solution. > > > >If not, then bright ideas are urgently solicited as to how to get > >around this. > > > >I also checked... POSIX make doesn't have an Include; they > >indicate that they considered it, but didn't end up requiring it. > > > >Who's the official arbiter of such calls? Jeff? RMS? > > I dunno about official arbiters, but the point I'm trying to make is that > insisting on ksh, a Posix sh, or anything better than V7 /bin/sh is a bad > idea. For some mysterious reason, no commercial Unix I've ever seen has a > Posix-compliant /bin/sh. There's a Posix-compliant shell hiding somewhere, > but just TRY to find it... I've seen it be > > /bin/posixsh > /bin/bsh > /bin/ksh > /usr/bin/ksh > /usr/posix/bin/sh > /usr/xpg4/bin/sh > /usr/lpp/something-I-forget/bin/sh > > And once you've found it, try to persuade Make to use it. That's nontrivial > too. Even gmake has this tendency to decide that it's going to ignore SHELL > and use /bin/sh. > > zw Actually, THAT problem is much deeper, and if it were solved the other problem would be solved as well. There is no standards requirement in either POSIX or TOG that there even BE a /bin/sh (or a /bin, for that matter; just sh is required). Having said that, I recognize that there are practical problems with that. On the other hand, POSIX conformant shells somehow have to hook up with a lot of POSIX-requiring #!/bin/sh. I realize that this isn't as easy as I make it sound, but if we were to fix the dependency on a file that needn't exist (and when it does, it's often wrong) then we'd not be tied to the (arguably inherently broken on many systems) /bin/sh. According to POSIX.2, the 'sh' found in $(getconf PATH) is required to be a POSIX shell. That's probably the way to pull this rabbit out of its hat. I don't know about gmake, but a make that didn't get the POSIX shell would be in violation of the POSIX standard, as well. (Presuming the vendor claims conformance.) Donn