bug-make
[Top][All Lists]
Advanced

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

Re: patch to support output synchronization under -j


From: David Boyce
Subject: Re: patch to support output synchronization under -j
Date: Fri, 15 Apr 2011 10:12:19 -0400

On Thu, Apr 14, 2011 at 4:30 PM, David Boyce <address@hidden> wrote:
> I don't know why this hasn't occurred to me or the authors of similar
> programs before, but it appears to be possible to get a lock on any
> writable file descriptor - for instance stdout or stderr, or one of
> the jobserver-fds. I just changed syncsh to synchronize around a lock
> on stdout and it seems to work. This looks much more elegant than
> specifying a writable file.

Attached is an updated patch with some improvements:

- The feature is turned on by a special target currently called
.PARALLELSYNC. No filename required.
- It uses stdout as its semaphore.
- It combines output into one temp file iff the inherited stdout and
stderr are already combined, as suggested by Howard Chu.

Very lightly tested, of course. See the Makefile.synctest for a usage example.

David

Attachment: make-sync.patch
Description: Binary data

Attachment: Makefile.synctest
Description: Binary data


reply via email to

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