Skip to content

Commit 6127798

Browse files
ulfalizermasahir0y
authored andcommitted
Makefile: Fix lying comment re. silentoldconfig
The comment above the silentoldconfig invocation is outdated. 'make oldconfig' updates just .config and doesn't touch the include/config/ tree. This came up in https://lkml.org/lkml/2018/2/12/415. While fixing the comment, make it more informative by explaining the purpose of the unfortunately named silentoldconfig. I can't make sense of the comment re. auto.conf.cmd and a cleaned tree. include/config/auto.conf and include/config/auto.conf.cmd are both created simultaneously by silentoldconfig (in scripts/kconfig/confdata.c, by conf_write_autoconf()), and nothing seems to remove auto.conf.cmd that wouldn't remove auto.conf. Remove that part of the comment rather than blindly copying it. It might be a leftover from an older way of doing things. The include/config/auto.conf.cmd prerequisite might be there to ensure that silentoldconfig gets rerun if conf_write_autoconf() fails between writing out auto.conf.cmd and auto.conf (a comment in the function indicates that auto.conf is deliberately written out last to mark completion of the operation). It seems the Makefile dependency between include/config/auto.conf and .config would already take care of that though, since include/config/auto.conf would still be out of date re. .config if the operation fails. Cop out and leave the prerequisite in for now. Signed-off-by: Ulf Magnusson <ulfalizer@gmail.com> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
1 parent 4a3928c commit 6127798

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

Makefile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -579,10 +579,9 @@ ifeq ($(KBUILD_EXTMOD),)
579579
# To avoid any implicit rule to kick in, define an empty command
580580
$(KCONFIG_CONFIG) include/config/auto.conf.cmd: ;
581581

582-
# If .config is newer than include/config/auto.conf, someone tinkered
583-
# with it and forgot to run make oldconfig.
584-
# if auto.conf.cmd is missing then we are probably in a cleaned tree so
585-
# we execute the config step to be sure to catch updated Kconfig files
582+
# The actual configuration files used during the build are stored in
583+
# include/generated/ and include/config/. Update them if .config is newer than
584+
# include/config/auto.conf (which mirrors .config).
586585
include/config/%.conf: $(KCONFIG_CONFIG) include/config/auto.conf.cmd
587586
$(Q)$(MAKE) -f $(srctree)/Makefile silentoldconfig
588587
else

0 commit comments

Comments
 (0)