From 526396b723a38dbeed35cb9e80814084b9f56329 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Sat, 3 Feb 2024 00:58:04 +0900 Subject: kconfig: write Kconfig files to autoconf.cmd in order Currently, include/config/autoconf.cmd saves included Kconfig files in reverse order. While this is not a big deal, it is inconsistent with other *.cmd files generated by fixdep. Output the included Kconfig files in the included order. Signed-off-by: Masahiro Yamada --- scripts/kconfig/confdata.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'scripts/kconfig/confdata.c') diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index 7f0aa39b68c1..f6a96fdddb7e 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -20,6 +20,8 @@ #include "lkc.h" +struct gstr autoconf_cmd; + /* return true if 'path' exists, false otherwise */ static bool is_present(const char *path) { @@ -972,7 +974,6 @@ end_check: static int conf_write_autoconf_cmd(const char *autoconf_name) { char name[PATH_MAX], tmp[PATH_MAX]; - struct file *file; FILE *out; int ret; @@ -993,9 +994,7 @@ static int conf_write_autoconf_cmd(const char *autoconf_name) return -1; } - fprintf(out, "deps_config := \\\n"); - for (file = file_list; file; file = file->next) - fprintf(out, "\t%s \\\n", file->name); + fputs(str_get(&autoconf_cmd), out); fprintf(out, "\n%s: $(deps_config)\n\n", autoconf_name); -- cgit