*BSD News Article 8109


Return to BSD News archive

Newsgroups: comp.unix.bsd
Path: sserve!manuel.anu.edu.au!munnari.oz.au!news.hawaii.edu!ames!riacs!speclab.cr.usgs.gov!ngorelic
From: ngorelic@speclab.cr.usgs.gov.cr.usgs.gov (Noel S. Gorelick)
Subject: [386BSD] Shell scripts don't recognize #!
Message-ID: <1992Nov25.233031.4419@riacs.edu>
Sender: news@riacs.edu
Reply-To: ngorelic@speclab.cr.usgs.gov
Organization: MercWorks, Denver
X-Newsreader: TIN [version 1.1 PL6]
Date: Wed, 25 Nov 92 23:30:31 GMT
Lines: 19

Did I miss this somewhere, or is it something specific to me?

In both Csh and Ash, shell scripts won't recognize the #!/path/program
statement at the top of the file.  (Specifically, the GNU configure
script has #!/bin/sh at the top, and when running in Csh, it tried to
interpret the file as a csh script (lots of errors about 'trap - commmand
not found' and stuff like that.  Stuff that *IS* in /bin/sh)

I can force /bin/sh to run the script with "sh configure", and everything
works fine, but this is hardly an adequate solution.

Also, when I manually started /bin/sh and tried to run a csh script, it
was trying to interpret it as sh script.  Whats the deal?  Am I just
missing something simple, or is this an actual bug like thing?

--
"You want it should sing too?"   | /*  Yeah we got dogs and Valvoline
  ngorelic@speclab.cr.usgs.gov   |     Its a pretty damn good time.    */
"Life is pain. Anyone that tells you different is trying to sell you something"