bug-make
[Top][All Lists]
Advanced

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

Re: .SECONDARY unexpectedly affects rule invocation


From: Dmitry Goncharov
Subject: Re: .SECONDARY unexpectedly affects rule invocation
Date: Tue, 4 Oct 2022 23:51:34 -0400



On Tuesday, October 4, 2022, Mikhail Pomaznoy <mikpom@mikpom.ru> wrote:

Martin's snippet indeed recapitulates the behavior resulted in my initial report.

As for Dmitry's reply: I don't understand if make does what's expected or not.


Works as  documented. Even though I am not sure this particular case was envisioned.


 I believed that A.4 being a prereq of A.4.ind will always trigger the latter being rebuilt if A.4 is newer.

It will, if A.4 is newer. In this case A.4 is not newer. A.4 is missing when make considers A.4.ind.

As a side note: I use make for running pipelines and add .SECONDARY routinely because I don't want anything to be deleted as temporary file


 Secondary without prerequisites is a bad idea. 

Regards, Dmitry

-Mikhail

On 10/5/22 09:58, Dmitry Goncharov wrote:
On Tue, Oct 4, 2022 at 10:08 PM Martin Dorey
<Martin.Dorey@hitachivantara.com> wrote:
 Isn't this slightly simplified example sufficient to demonstrate the same behavior...
A.4 is a preqreq to T.1 and also a prereq to A.4.ind.
A.4.ind is present and that's why make skips building secondary A.4
and keeps A.4.ind intact, while walking through A.4.ind prereqs.
T.1 is missing and this causes make to build A.4 in order to build
T.1, after A.4.ind is done with.

regards, Dmitry

reply via email to

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