How does make determine which shells to invoke when executing external commands?

Warren Young warren@etr-usa.com
Thu Jun 6 16:25:00 GMT 2013


On 6/5/2013 20:43, Hua Ai wrote:
> I thought this is a cygwin issue since windows
> commands were invoked.

Cygwin make should *always* be using /bin/sh to interpret commands, 
unless you've overridden it with SHELL.

Type this into a Makefile:

	all:
         	@echo Shell is $(SHELL)

Then say "make" in that directory.  It should confirm my assertion.

If it tells you something different on a problem machine, say "make 
--version" and verify that it says "Built for i686-pc-cygwin".

> We don't have MinGW, but we do have multiple versions of a software
> (development tools from Altera) installed on these computers, which
> all contains a copy of cygwin (different versions but all with make).

Are you *certain* Altera is shipping Cygwin GNU make and not MinGW make?

Either way, you're kind of in a bind.

If Altera is shipping MinGW GNU make, you have the conflict I originally 
proposed.

If they are in fact shipping Cygwin, you have this problem:

	http://www.cygwin.com/faq.html#faq.using.multiple-copies

(Items 4.19 through 4.23.)

> This makefile however was run from a standalone cygwin.

What does it say when you say "which make"?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple



More information about the Cygwin mailing list