bug-make
[Top][All Lists]
Advanced

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

Re: output from $(error) lost with output sync


From: Paul Smith
Subject: Re: output from $(error) lost with output sync
Date: Tue, 14 Jan 2014 00:31:24 -0500

I fixed this one locally a couple of days ago; sorry for not pushing.
I'll do that shortly.

I don't think this change is sufficient because if output_sync !=
&make_sync then make_sync is never dumped with the change below.


On Tue, 2014-01-14 at 06:21 +0100, Frank Heckenbach wrote:
> Oliver Kiddle wrote:
> 
> > Given the following Makefile, the output from the error function is
> > being lost when the gmake 4 output-sync is enabled:
> >
> > [...]
> 
> With assertions active I even get this error:
> 
> % make -O
> make: main.c:3409: die: Assertion `output_context == &make_sync'
> failed.
> 
> Aborted
> 
> I tried inserting "OUTPUT_UNSET ();" in func_error(), case 'e'. This
> fixes the above problem, but still fails with fatal() called from
> other functions, e.g.:
> 
> foo:
>       echo $(wordlist 0, 0, foo)
> 
> So the problem is more general. ISTM the assumption in die() that
> output_context is either NULL or &make_sync is just not valid, since
> fatal() can be called from basically anywhere. So I made this change
> which seems to fix the problem.
> 
> --- main.c.orig       2014-01-14 05:55:19.000000000 +0100
> +++ make/main.c       2014-01-14 06:14:00.000000000 +0100
> @@ -3406,9 +3406,8 @@
>  
>        if (output_context)
>          {
> -          assert (output_context == &make_sync);
> +          output_close (output_context);
>            OUTPUT_UNSET ();
> -          output_close (&make_sync);
>          }
>  
>        output_close (NULL);





reply via email to

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