help-make
[Top][All Lists]
Advanced

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

Re: Quietly and eagerly deleting intermediate files


From: Paul Smith
Subject: Re: Quietly and eagerly deleting intermediate files
Date: Tue, 10 Jan 2017 13:50:18 -0500

On Mon, 2017-01-09 at 12:39 -0700, Jed Brown wrote:
> Is there a way, short of recursive make, to eagerly delete the
> intermediates?

There is not such a way.  Intermediates are always and only removed at
the end of the make run.  It sort of has to be this way since make
cannot know whether or not the intermediate file will be needed again,
until it's completed all its work.

Make doesn't first compute all the things that need to be built, then
walks the list building them.  Instead it just starts at the initial
goal node in the graph and keeps building things until it discovers
that there's nothing left to be built.

Using recursion is your only option, if you must have the intermediate
files removed as you go (and you want make to do it rather than doing
it yourself in your makefile).



reply via email to

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