[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug #33138] .PARLLELSYNC enhancement with patch
From: |
Paul Smith |
Subject: |
Re: [bug #33138] .PARLLELSYNC enhancement with patch |
Date: |
Sat, 04 May 2013 09:33:29 -0400 |
On Sat, 2013-05-04 at 08:57 +0200, Frank Heckenbach wrote:
> I shouldn't have written that. :-( Shortly afterwards, I found a bug
> or perhaps two:
>
> foo:
> @echo foo
> address@hidden bar
>
> (a)
> % make -Ojob
> foo
> bar
> foo
>
> (b)
> % make -Otarget
> bar
> foo
>
> As you see, (a) "-Ojob" writes "foo" twice and (b) "-Otarget" writes
> the messages in the wrong order.
The second one is known and I mentioned it the other day (hard to keep
up with all the messages, I know). I'm working on a fix.
The first one I've seen but hadn't had time to debug. I'll look at your
patch. I left the truncate where it was rather than doing it after the
sync_output() because I was hoping to avoid truncating a file that we'll
never use again anyway, but I guess it isn't a big deal.
COMMANDS_RECURSE _does_ mean to recurse. The reason for the '+'
prerequisite is to tell make that this line, even though it may not look
like it, will run a recursive make.
Since make doesn't parse the command line it can't know for sure which
ones actually recurse. It uses a heuristic, by looking for $(MAKE) or
${MAKE} in the unexpanded line. But this is easily defeated if your
sub-make invocation doesn't use that variable for some reason. Hence,
using "+" to force it.