This is the mail archive of the
cygwin@sources.redhat.com
mailing list for the Cygwin project.
Re: Can't exec /bin/sh.exe at ./dog.sh line 1.
- To: cygwin at sourceware dot cygnus dot com
- Subject: Re: Can't exec /bin/sh.exe at ./dog.sh line 1.
- From: Chris Faylor <cgf at cygnus dot com>
- Date: Thu, 28 Sep 2000 17:14:32 -0400
- Cc: David Starks-Browning <starksb at ebi dot ac dot uk>
- References: <39D373A8.1AF731C0@openmarket.com> <39D3B161.C49B2F93@openmarket.com>
- Reply-To: cygwin at sources dot redhat dot com
On Thu, Sep 28, 2000 at 05:00:17PM -0400, Guy T. Moore Jr. wrote:
>Thanks for all the replies. None solved it.
>Let me cut to the chase with the problem that more resembles my problem:
>
>Using Cygwin 1.1.4.
>I'm on C: drive, an NTFS partition.
>CYGWIN is set to "binmode ntea"
>I do not have McAfee anti-virus software running.
>my machine has been rebooted and am in a fresh window.
>
>
>This is my script called dog.sh and has been chmod to 777.
>
> #!/bin/sh.exe
> #
> echo "Hello"
> echo $0
> eval "exec perl -S $0 " <------- problem line
> if $avariablenotdefined;
> print "GoodBye";
>
>
>
>When I execute this script, I get an error:
>
> $ c:/dog.sh
> Hello
> c:/dog.sh
> Can't exec /bin/sh.exe at ./dog.sh line 1.
>
>Why is Cygwin exec'ing /bin/sh.exe when it should be exec'ing perl?
>And why can't Cygwin exec /bin/sh.exe anyways?
The "Can't exec /bin/sh.exe at ./dog.sh line 1" message is coming from
*perl*. You're not running a cygwin version of perl so it doesn't know
how to find /bin/sh.exe.
This really should be a FAQ, I suppose, if it isn't already.
cgf
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com