[Top][All Lists]

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

Re: GNU make 4.3.90 release candidate available

From: Paul Smith
Subject: Re: GNU make 4.3.90 release candidate available
Date: Mon, 26 Sep 2022 15:14:37 -0400
User-agent: Evolution 3.44.4 (by Flathub.org)

On Mon, 2022-09-26 at 21:46 +0300, Eli Zaretskii wrote:
> > On Mon, 2022-09-26 at 20:23 +0300, Eli Zaretskii wrote:
> > > The following tests should be disabled on MS-Windows, because
> > > they cannot possibly work:
> > 
> > I have access to a VM running Windows 10 with a relatively recent
> > Visual Studio install, with a recent Perl, and with the Git for
> > Windows binaries (from MinGW I assume) on my PATH.  No other cygwin
> > or MinGW.
> Some binaries from Git for Windows are MinGW binaries, but some are
> MSYS2 binaries.  All those for which Git Bash says they are in /bin
> (as opposed to /mingw64/bin) are MSYS2 binaries, they depend on MSYS
> DLL and don't use the Windows C runtime.  MSYS2 is a fork of Cygwin,
> with a few subtle features that allow it to invoke native Windows
> programs without confusing them with Unix-style file names and PATH.

To be honest I still don't think I understand all the intricacies of
this.  All I know is that I add:

  set "PATH=%PATH%;C:\Strawberry\perl\bin;C:\Git\usr\bin"

and everything "mostly works", with a relatively small number of things
disabled in the test suite (on Windows I get 1083 tests passed in 124
categories, while on Linux it's 1213 tests passed in 134 categories).

> > In this environment I can do this (in a Windows cmd.exe shell):
> > 
> >   tar xzf make-4.3.90.tar.gz
> >   cd make-4.3.90
> >   .\build_w32.bat
> >   .\WinRel\gnumake.exe check
> > 
> > This builds with Visual Studio and I get zero test failures.
> > 
> > I assume a big part of this is that make is choosing bash as its
> > shell, from the Git for Windows install, not cmd.exe.  Plus other
> > POSIX tools are available.
> Of course, it's because you set up Bash as the shell Make uses!

Just to say, I didn't "set up Bash as the shell".  I set my PATH as
above, and ran the commands as above.  If make is choosing to use bash
it's because it was found on PATH, not because I made any explicit
decision to choose it.

> Which means many tests run in an environment that will rarely happen
> in Real Life, when the native port of Make is used with cmd.exe as
> the shell, not with MSYS2 Bash.

I agree that using cmd.exe as make's shell would be a good thing to
test, but IMO it's not actually all that rare for developers to have
Git for Windows installed and on their PATH (including the usr/bin
directory not just git.exe) these days, given how pervasive Git is.

> The tests do need a few Unix tools (like 'sleep', 'cat', 'touch', and
> maybe others), but those are available as native MinGW ports; whereas
> Bash isn't.  Moreover, when a Makefile uses the MSYS2 Bash, it will
> generally invoke MSYS2 binaries of other tools, like 'cat' and
> 'touch' (unless you are very careful to set up your PATH for Git
> Bash).  So you end up using "foreign" tools to run the tests, and I
> find that less than optimal.  (It is, of course, much less time-
> consuming ;-)

:).  I usually run the tests on Windows before I push changes upstream,
but I'm mainly just making sure I didn't break anything egregious and
check that things basically compile and run, I'm not pretending that
I'm doing any comprehensive testing.  There are so many different
environments to check on Windows and I don't understand how to install
them, or even how to know which one I'm using.

But, if it would be more helpful to not have C:\Git\usr\bin on my PATH
during my basic tests I can remove it.

> > >  . 1 test in misc/bs-nl that uses single quotes around newlines
> > >  . 1 test in misc/general3 that uses single quotes around newlines
> > >  . 1 test in misc/general4 that unsets PATH (this cannot work on
> > >    Windows because Make will be unable to find the DLLs against which
> > >    it was linked, so it fails to start without valid PATH)
> > >  . targets/ONESHELL in its entirety (this feature doesn't work on
> > >    Windows)
> The last two should fail with MSYS Bash as well, I think.

All I can say is that whatever tests are not currently marked to be
omitted on Windows, work for me in the above environment.  I just
checked and for targets/ONESHELL I got 4 tests passed and for
misc/general4 I got 10 tests passed.

reply via email to

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