Re: Sporadic GNU make jobserver unavailable

Dimitry Andric via Cygwin <[email protected]>
Newsgroups gmane.os.cygwin
Message-ID <[email protected]>
On 5 Dec 2025, at 19:26, Dimitry Andric <[email protected]> wrote:
> 
> On 5 Dec 2025, at 14:37, Brian Inglis via Cygwin <[email protected]> wrote:
>> 
>> 
>> On 2025-12-05 02:18, Dimitry Andric via Cygwin wrote:
>>> We're using Cygwin make to build several projects in parallel mode, e.g.
>>> with -j 4 or sometimes higher settings, depending on the core count of
>>> the machine.
>>> Sporadically, and then I'm talking about "once a week" or so, random
>>> jobs will fail with a non-repeatable error, and in _every_ case these
>>> failures are preceded by a warning from make:
>>>  make[4]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
>>> Obviously the "Add '+' to parent rule" is nonsensical, since simply
>>> running exactly the same job again almost always works fine. But there
>>> is something flaky about make's jobserver under Windows.
>>> FWIW one machine I just observed this on has the make-4.4.1-2 package,
>>> which should use the "pipe" jobserver, if I interpret
>>> https://cygwin.com/pipermail/cygwin-announce/2023-March/010972.html
>>> correctly.
>>> Does anybody know a way to further debug this issue? It must be some
>>> rare race condition...
>> 
>> https://stackoverflow.com/questions/60702726/warning-jobserver-unavailable-using-j1-add-to-parent-make-rule
> 
> Yeah, I've read all those FAQs. The problem isn't in our Makefiles,
> since they run just fine on Linux. It's only on Windows under Cygwin
> that they break. :)
> 
> I'm fairly certain it's a make bug, but whether it's Windows specific,
> or just a Cygwin issue, is not yet clear.

I just read https://cygwin.com/pipermail/cygwin-announce/2023-March/010972.html,
which says:

> The default version [4.4.1-1] is built with jobserver using FIFO and
> the test version [4.4.1-2] using pipe.
> In same complex corner case the previous 4.4-1 was reported to
> fail and it is unclear if the pipe version is the solution
> or just a side coincidence.
> Please report any problem on any version.

From Marco's post it is not really clear what the failure was, but our
Windows systems all run 4.4.1-2 since that is the latest version, so
I'll try reverting some boxes to 4.4.1-1 to see if that helps.

-Dimitry


-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.