Subject: Re: #!/bin/sh troubles
From: [email-masked] (Christopher Seawood)

29 Dec 1998 20:33:26 -0800
Message-ID: <[email-masked]>
References: <[email-masked]>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
To: "Christopher G. Faylor" <[email-masked]>
Cc: [email-masked]

On 29 Dec 1998, Christopher G. Faylor wrote:

> In article <[email-masked]>,
> Christopher Seawood <[email-masked]> wrote:
> >On Mon, 7 Dec 1998, it was written:
> >> I copied b20.1's sh.exe to /bin/sh and cp removed the execute permissions.
> >> Chmod'ing the binary did not work either.  So I moved /bin/sh to 
> >> /bin/sh.exe.  Autoconf runs and spits 6 lines of control chars, each
> >> ending with ": not found".  Then it spits out
> >>      /bin/sh.exe: 11: Syntax error: ")" unexpected.  
> >> 
> >
> >Well, I was playing with the problem again today when I accidentally
> >typed:  sh /bin/sh.exe .  And surprise, I got the same 6 lines of control
> >chars so could it be that sh is attempting to run itself instead of the
> >shell script that calls it when I try to run just ./configure or autoconf?
> 
> I'm not sure why you're copying /bin/sh.exe to /bin/sh but it is not
> necessary and will only confuse things.

Just trying to see if it would make things work again.

> Scripts that begin with '#!/bin/sh' behave properly under Cygwin.  Adding
> the .exe to the /bin/sh is optional and probably should be avoided if your
> goal is to create portable scripts.

I never added the .exe to the #!/bin/sh that's in the autoconf script.
The first line of the autoconf script is still #!/bin/sh.  What I was
trying to point out is that the error message that I get when I run
autoconf (or any shell script) is the same as the one I get when I do 'sh
/bin/sh.exe'. I'm looking into the spawn code now but I can't seem to get
a new cygwin1.dll compiled with debugging on.
 
Regards,
Christopher

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