Thread (37 messages) 37 messages, 3 authors, 2024-12-28

Re: [PATCH v2 3/5] Makefile: drop unneeded indirection for GIT-VERSION-GEN outputs

From: Jeff King <hidden>
Date: 2024-12-20 15:53:44

On Fri, Dec 20, 2024 at 01:22:47PM +0100, Patrick Steinhardt wrote:
Some of the callsites of GIT-VERSION-GEN generate the target file with a
"+" suffix first and then move the file into place when the new contents
are different compared to the old contents. This allows us to avoid a
needless rebuild by not updating timestamps of the target file when its
contents will remain unchanged anyway.

In fact though, this exact logic is already handled in GIT-VERSION-GEN,
so doing this manually is pointless. This is a leftover from an earlier
version of 4838deab65 (Makefile: refactor GIT-VERSION-GEN to be
reusable, 2024-12-06), where the script didn't handle that logic for us.

Drop the needless indirection.
Nice. I think when we can do stuff like this in an actual script instead
of in a Makefile, the result is more readable.

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help