kbuild: hide commands to run Kconfig, and show short log for syncconfig
Some targets (localyesconfig, localmodconfig, defconfig) hide the command running, but the others do not. Users know which Kconfig flavor they are running, so it is OK to hide the command. Add $(Q) to all commands consistently. If you want to see the full command running, pass V=1 from the command line. syncconfig is the exceptional case, which occurs without explicit command invocation by the user. Display the Kbuild-style log for it. The ugly bare log will go away. [Before] scripts/kconfig/conf --syncconfig Kconfig [After] SYNC include/config/auto.conf Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
This commit is contained in:
parent
695afd3d7d
commit
23cd88c913
5
Makefile
5
Makefile
|
@ -707,8 +707,11 @@ $(KCONFIG_CONFIG):
|
||||||
# This exploits the 'multi-target pattern rule' trick.
|
# This exploits the 'multi-target pattern rule' trick.
|
||||||
# The syncconfig should be executed only once to make all the targets.
|
# The syncconfig should be executed only once to make all the targets.
|
||||||
# (Note: use the grouped target '&:' when we bump to GNU Make 4.3)
|
# (Note: use the grouped target '&:' when we bump to GNU Make 4.3)
|
||||||
|
quiet_cmd_syncconfig = SYNC $@
|
||||||
|
cmd_syncconfig = $(MAKE) -f $(srctree)/Makefile syncconfig
|
||||||
|
|
||||||
%/config/auto.conf %/config/auto.conf.cmd %/generated/autoconf.h: $(KCONFIG_CONFIG)
|
%/config/auto.conf %/config/auto.conf.cmd %/generated/autoconf.h: $(KCONFIG_CONFIG)
|
||||||
$(Q)$(MAKE) -f $(srctree)/Makefile syncconfig
|
+$(call cmd,syncconfig)
|
||||||
else # !may-sync-config
|
else # !may-sync-config
|
||||||
# External modules and some install targets need include/generated/autoconf.h
|
# External modules and some install targets need include/generated/autoconf.h
|
||||||
# and include/config/auto.conf but do not care if they are up-to-date.
|
# and include/config/auto.conf but do not care if they are up-to-date.
|
||||||
|
|
|
@ -20,19 +20,19 @@ endif
|
||||||
unexport CONFIG_
|
unexport CONFIG_
|
||||||
|
|
||||||
xconfig: $(obj)/qconf
|
xconfig: $(obj)/qconf
|
||||||
$< $(silent) $(Kconfig)
|
$(Q)$< $(silent) $(Kconfig)
|
||||||
|
|
||||||
gconfig: $(obj)/gconf
|
gconfig: $(obj)/gconf
|
||||||
$< $(silent) $(Kconfig)
|
$(Q)$< $(silent) $(Kconfig)
|
||||||
|
|
||||||
menuconfig: $(obj)/mconf
|
menuconfig: $(obj)/mconf
|
||||||
$< $(silent) $(Kconfig)
|
$(Q)$< $(silent) $(Kconfig)
|
||||||
|
|
||||||
config: $(obj)/conf
|
config: $(obj)/conf
|
||||||
$< $(silent) --oldaskconfig $(Kconfig)
|
$(Q)$< $(silent) --oldaskconfig $(Kconfig)
|
||||||
|
|
||||||
nconfig: $(obj)/nconf
|
nconfig: $(obj)/nconf
|
||||||
$< $(silent) $(Kconfig)
|
$(Q)$< $(silent) $(Kconfig)
|
||||||
|
|
||||||
build_menuconfig: $(obj)/mconf
|
build_menuconfig: $(obj)/mconf
|
||||||
|
|
||||||
|
@ -68,12 +68,12 @@ simple-targets := oldconfig allnoconfig allyesconfig allmodconfig \
|
||||||
PHONY += $(simple-targets)
|
PHONY += $(simple-targets)
|
||||||
|
|
||||||
$(simple-targets): $(obj)/conf
|
$(simple-targets): $(obj)/conf
|
||||||
$< $(silent) --$@ $(Kconfig)
|
$(Q)$< $(silent) --$@ $(Kconfig)
|
||||||
|
|
||||||
PHONY += savedefconfig defconfig
|
PHONY += savedefconfig defconfig
|
||||||
|
|
||||||
savedefconfig: $(obj)/conf
|
savedefconfig: $(obj)/conf
|
||||||
$< $(silent) --$@=defconfig $(Kconfig)
|
$(Q)$< $(silent) --$@=defconfig $(Kconfig)
|
||||||
|
|
||||||
defconfig: $(obj)/conf
|
defconfig: $(obj)/conf
|
||||||
ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG)),)
|
ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG)),)
|
||||||
|
@ -111,7 +111,7 @@ tinyconfig:
|
||||||
# CHECK: -o cache_dir=<path> working?
|
# CHECK: -o cache_dir=<path> working?
|
||||||
PHONY += testconfig
|
PHONY += testconfig
|
||||||
testconfig: $(obj)/conf
|
testconfig: $(obj)/conf
|
||||||
$(PYTHON3) -B -m pytest $(srctree)/$(src)/tests \
|
$(Q)$(PYTHON3) -B -m pytest $(srctree)/$(src)/tests \
|
||||||
-o cache_dir=$(abspath $(obj)/tests/.cache) \
|
-o cache_dir=$(abspath $(obj)/tests/.cache) \
|
||||||
$(if $(findstring 1,$(KBUILD_VERBOSE)),--capture=no)
|
$(if $(findstring 1,$(KBUILD_VERBOSE)),--capture=no)
|
||||||
clean-files += tests/.cache
|
clean-files += tests/.cache
|
||||||
|
|
Loading…
Reference in New Issue