From: Warren Young <warren@etr-usa.com>
To: Cygwin-L <cygwin@cygwin.com>
Subject: Re: How does make determine which shells to invoke when executing external commands?
Date: Wed, 05 Jun 2013 16:42:00 -0000 [thread overview]
Message-ID: <51AF6A55.2090203@etr-usa.com> (raw)
In-Reply-To: <CAPzB_RzA3LBR8QKZA0NT6UJmkt6dr=qHj-s85RmY2xAd4K3KAQ@mail.gmail.com>
On 6/5/2013 09:32, Hua Ai wrote:
>
> I have gone through FAQ and mailing lists but couldn't find an answer
> to this.
The answer is in the GNU make docs, or in the O'Reilly book if you prefer.
> Especially, this line:
>
> @mkdir -p $(dir $@)
>
> It seems that, for the computers where it didn't work, the makefile
> always invokes the mkdir from windows (Windows 7 64bit).
That means those computers have a native Windows version of GNU make on
them, most likely the one from MinGW. MinGW GNU make is built to use
cmd.exe to interpret shell commands, not /bin/sh as Cygwin's GNU make
does by default.
The docs will further enlighten you about how the SHELL variable can
override this default behavior. I suspect "SHELL=/bin/sh" still won't
do the right thing, though, since MinGW GNU make doesn't understand
POSIX paths. Something like SHELL=c:\cygwin\bin\sh.exe *might* work.
A superior solution is to get everyone to use Cygwin make.
If you can't do that, because you don't have any influence over the
software installed on the other computers, you might have to switch to
one of the portable Makefile builders, so you can ship both POSIX and
MinGW makefiles. Bakefile (http://bakefile.org/) can do this for sure.
CMake and Scons probably can, too.
--
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
next prev parent reply other threads:[~2013-06-05 16:42 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-05 15:32 Hua Ai
2013-06-05 16:42 ` Warren Young [this message]
2013-06-06 2:43 ` Hua Ai
2013-06-06 10:35 ` Andrey Repin
2013-06-06 16:25 ` Warren Young
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51AF6A55.2090203@etr-usa.com \
--to=warren@etr-usa.com \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).