Message-Id: <200002292218.RAA12069@delorie.com> Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com From: "Charlie Hand" To: cygwin AT sourceware DOT cygnus DOT com Date: Tue, 29 Feb 2000 14:19:21 -0800 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Subject: Re: Make problem Reply-to: charlie AT hand-family DOT org In-reply-to: <4.1.20000229143001.02152f00@pop.mathworks.com> References: <200002291816 DOT NAA15176 AT smtp DOT mathworks DOT com> X-mailer: Pegasus Mail for Win32 (v3.12a) > At 10:16 AM 2/29/00 -0800, Charlie Hand wrote: > >> I'm running bash 2.06 on Windows98. > >> > >> I'm trying to learn how to use make in this environment. > >> > >> Every time make tries to execute a command, it says: > >> /c: /c: No such file or directory > >> > >> It gives this same message regardless of the command. > >> > >> For example, for the following small makefile: > >> > >> SHELL = bash > >> ProjectX:: > >> echo hello > >> > >> The output is: > >> > >> "C:/cygnus/cygwin-b20/H-i586-cygwin32/bin/bash.exe"-2.02$ make > >> echo hello > >> /c: /c: No such file or directory > >> make: *** [ProjectX] Error 127 > >> > >> I can run the command "echo hello" at the bash prompt, and it runs > >> correctly. In general, I can run commands in the shell, and never > >> have any problems, nor do I ever see this "/c: /c:" thing. > >> > >> I've tried the --win32 switch, and it doesn't make any difference. > > > >I removed the SHELL=bash assignment, and it works correctly. It > >even appears to be running commands in bash. > > > > This is what is happening, Charlie. You are running Cygnus make in its > win32 mode. In this mode, make uses the DOS command shell switch /c to > launch commands. However, you then tell make to use bash as the SHELL. In > win32 mode, make does know anything about Unix shells. So it continues to > use /c as the command switch even though it is now using unknowingly a Unix > shell. Thus, in effect with your little make file, make is doing > > bash /c "echo hello" > > Now, if you don't believe me, fire up bash in Emacs and enter > > bash -c "echo hello" > > and then > > bash /c "echo hello" > > and observe the output of make in each case. You will note that in the > latter case the error message is exactly the one you are getting. If you > want to use bash as your make shell, you have to run make in Unix mode, > which you do by setting the Cygnus environment variable MAKE_MODE to Unix. > This BTW is in the FAQ item that I posted in response to your plea for any > information on the Cygnus version of make and that you then cavalierly > dismissed as obvious. The result is the same for: MAKE_MODE=UNIX SHELL=bash target:: ls or SHELL=bash target:: ls The only way to run simple commands such as "ls" or "echo hello" was to delete SHELL=bash. -Charlie -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com