make-w32
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mingw make problem


From: Eli Zaretskii
Subject: Re: mingw make problem
Date: Fri, 18 Aug 2006 14:07:10 +0300

> Date: Thu, 17 Aug 2006 21:37:37 -0400
> From: "William A. Hoffman" <address@hidden>
> 
> >>Make 3.81 adds a feature whereby you can say "SHELL = cmd.exe" and
> >>have it use CMD even if sh.exe is on your PATH.  Previous versions of
> >>Make didn't allow even that.
> >
> >This behavior was controlled under the old Cygwin make via a --win32
> >option (an option that RMS repeatedly asked me to change, FWIW).
> >
> >So, it sounds like one solution to the problem might be to just use
> >SHELL=cmd.exe.
> 
> But I want it to use sh.exe.

If this turns out to be some basic incompatibility between the quoting
of native and Cygwin programs, you may have no other alternatives with
the MinGW Make but use cmd.exe.  That is, unless someone debugs what
happens in the Cygwin sh.exe end, and explains why this doesn't work
for you, but does work for me with native ports.

> The makefiles are mostly POSIX, the only non-POSIX thing in them is
> the driver letter stuff.  C:/foo/bar.C.  So cmd.exe does not like
> paths like that.

File names like "C:/foo/bar.C" _will_ work with cmd.exe if you quote
them with double quotes.  The Emacs build procedure on Windows uses
this, and I have yet to hear about any problems.

> Also, cmd.exe has problems with long command lines.

Every shell has command-line length limitations.

Also, please note that GNU Make calls the shell only if the command
has some special characters which require the shell, such as
redirection.  Otherwise, Make invokes the program directly through
CreateProcess, in which case the command length limitations are less
severe.

> MSYS make would be a good choice, but it has the bad habit of
> changing command line options of dos programs into full paths to the
> msys mount point.

I think we already agreed that the best choice (for you) is to add
support for DOS file names to the Cygwin Make ;-)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]