]> git.tuebingen.mpg.de Git - paraslash.git/commit
build: Improve clean targets.
authorAndre Noll <maan@tuebingen.mpg.de>
Wed, 1 Jan 2025 21:24:03 +0000 (22:24 +0100)
committerAndre Noll <maan@tuebingen.mpg.de>
Tue, 25 Mar 2025 00:51:36 +0000 (01:51 +0100)
commitbaf345a6e3be92e478bc81f54ff7e15ab2c10e75
treece2254bdb5e55b505593e6ee579e0325855e2b2c
parent447eb3befdc74caafbffb275ef5507505a5398c6
build: Improve clean targets.

In a "fresh build" (e.g. after a make clean) we create the .d and the
.o file in one go to speed up this common case. However, if one runs
"make clean" followed by e.g. "make para_audioc", this will create
*all* object and dependency files, not just the ones needed to build
para_audioc. This behaviour is unfortunate because most dependencies
are irrelevant for a single target, and even the few which do matter
are ignored as well in this case because the object file does not
exist and needs to be recreated anyway,

Work around this shortcoming by shuffling the commands of the four
rules a little so that the clean target only removes object files
but keeps the dependency files.

Also remove the calls to SAY in the recipe of the clean targets because
with the rm commands spelled out it is clear what is being removed.
Makefile.real