Skip to content

Commit fd54f50

Browse files
vapiersravnborg
authored andcommitted
kbuild: use KECHO convenience echo
Convert a few echos in the build system to new $(kecho) so we get correct output according to build verbosity. Signed-off-by: Mike Frysinger <vapier@gentoo.org> [sam: added kecho in a few more places for O=... builds] Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
1 parent 5410ecc commit fd54f50

3 files changed

Lines changed: 7 additions & 14 deletions

File tree

‎Makefile‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -926,7 +926,7 @@ PHONY += prepare archprepare prepare0 prepare1 prepare2 prepare3
926926
# 2) Create the include2 directory, used for the second asm symlink
927927
prepare3: include/config/kernel.release
928928
ifneq ($(KBUILD_SRC),)
929-
@echo ' Using $(srctree) as source for kernel'
929+
@$(kecho) ' Using $(srctree) as source for kernel'
930930
$(Q)if [ -f $(srctree)/.config -o -d $(srctree)/include/config ]; then \
931931
echo " $(srctree) is not clean, please run 'make mrproper'";\
932932
echo " in the '$(srctree)' directory.";\
@@ -983,7 +983,7 @@ endef
983983
# directory for generated filesas used by some architectures.
984984
define create-symlink
985985
if [ ! -L include/asm ]; then \
986-
echo ' SYMLINK $@ -> include/asm-$(SRCARCH)'; \
986+
$(kecho) ' SYMLINK $@ -> include/asm-$(SRCARCH)'; \
987987
if [ ! -d include/asm-$(SRCARCH) ]; then \
988988
mkdir -p include/asm-$(SRCARCH); \
989989
fi; \
@@ -1096,7 +1096,7 @@ all: modules
10961096
PHONY += modules
10971097
modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux)
10981098
$(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order
1099-
@echo ' Building modules, stage 2.';
1099+
@$(kecho) ' Building modules, stage 2.';
11001100
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
11011101
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.fwinst obj=firmware __fw_modbuild
11021102

@@ -1360,7 +1360,7 @@ $(module-dirs): crmodverdir $(objtree)/Module.symvers
13601360
$(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@)
13611361

13621362
modules: $(module-dirs)
1363-
@echo ' Building modules, stage 2.';
1363+
@$(kecho) ' Building modules, stage 2.';
13641364
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
13651365

13661366
PHONY += modules_install

‎arch/blackfin/boot/Makefile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ $(obj)/vmlinux.gz: $(obj)/vmlinux.bin FORCE
2525

2626
$(obj)/vmImage: $(obj)/vmlinux.gz
2727
$(call if_changed,uimage)
28-
@echo 'Kernel: $@ is ready'
28+
@$(kecho) 'Kernel: $@ is ready'
2929

3030
install:
3131
sh $(srctree)/$(src)/install.sh $(KERNELRELEASE) $(BOOTIMAGE) System.map "$(INSTALL_PATH)"

‎scripts/Kbuild.include‎

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,22 +46,15 @@ kecho := $($(quiet)kecho)
4646
# - If they are equal no change, and no timestamp update
4747
# - stdin is piped in from the first prerequisite ($<) so one has
4848
# to specify a valid file as first prerequisite (often the kbuild file)
49-
chk_filechk = :
50-
quiet_chk_filechk = echo ' CHK $@'
51-
silent_chk_filechk = :
52-
upd_filechk = :
53-
quiet_upd_filechk = echo ' UPD $@'
54-
silent_upd_filechk = :
55-
5649
define filechk
5750
$(Q)set -e; \
58-
$($(quiet)chk_filechk); \
51+
$(kecho) ' CHK $@'; \
5952
mkdir -p $(dir $@); \
6053
$(filechk_$(1)) < $< > $@.tmp; \
6154
if [ -r $@ ] && cmp -s $@ $@.tmp; then \
6255
rm -f $@.tmp; \
6356
else \
64-
$($(quiet)upd_filechk); \
57+
$(kecho) ' UPD $@'; \
6558
mv -f $@.tmp $@; \
6659
fi
6760
endef

0 commit comments

Comments
 (0)