aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/Kbuild.include
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2018-11-29 20:05:29 -0500
committerMasahiro Yamada <yamada.masahiro@socionext.com>2018-12-01 09:13:14 -0500
commit67126965ee0856f0d1cdb10792a36eaf4b2f13c0 (patch)
tree95e95e7a7969d0faaf7c6bd5e13ad180a96e587f /scripts/Kbuild.include
parente5d289100d3aef3e83dc1b8303999e26d86acb7b (diff)
kbuild: refactor if_changed
'@set -e; $(echo-cmd) $(cmd_$(1)' can be replaced with '$(cmd)'. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'scripts/Kbuild.include')
-rw-r--r--scripts/Kbuild.include3
1 files changed, 1 insertions, 2 deletions
diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include
index ba297fdd7c52..87e188609ef7 100644
--- a/scripts/Kbuild.include
+++ b/scripts/Kbuild.include
@@ -251,8 +251,7 @@ any-prereq = $(filter-out $(PHONY),$?) $(filter-out $(PHONY) $(wildcard $^),$^)
251 251
252# Execute command if command has changed or prerequisite(s) are updated. 252# Execute command if command has changed or prerequisite(s) are updated.
253if_changed = $(if $(strip $(any-prereq) $(arg-check)), \ 253if_changed = $(if $(strip $(any-prereq) $(arg-check)), \
254 @set -e; \ 254 $(cmd); \
255 $(echo-cmd) $(cmd_$(1)); \
256 printf '%s\n' 'cmd_$@ := $(make-cmd)' > $(dot-target).cmd, @:) 255 printf '%s\n' 'cmd_$@ := $(make-cmd)' > $(dot-target).cmd, @:)
257 256
258# Execute the command and also postprocess generated .d dependencies file. 257# Execute the command and also postprocess generated .d dependencies file.