> > I am working to build a Kconfig based configuration menu and I need to > > include a prefix variable > > to source command. How do I do this? Kconfig-language.txt doesn't > > explain this. Your > > response will be highly appreciated... > Not supported today. > I recall I did this some time ago but that patch is long gone. > It is trivially to add. Found my old patch... It is one year old or more so may not apply cleanly.
Sam diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index ccd4513..4be63d9 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -44,7 +44,7 @@ static void conf_warning(const char *fmt conf_warnings++; } -static char *conf_expand_value(const char *in) +char *conf_expand_value(const char *in) { struct symbol *sym; const char *src; diff --git a/scripts/kconfig/lkc.h b/scripts/kconfig/lkc.h index 527f60c..95b7f44 100644 --- a/scripts/kconfig/lkc.h +++ b/scripts/kconfig/lkc.h @@ -61,7 +61,7 @@ char *zconf_curname(void); /* confdata.c */ extern const char conf_def_filename[]; - +char *conf_expand_value(const char*); char *conf_get_default_confname(void); /* kconfig_load.c */ diff --git a/scripts/kconfig/zconf.l b/scripts/kconfig/zconf.l index cfa4607..ba55e87 100644 --- a/scripts/kconfig/zconf.l +++ b/scripts/kconfig/zconf.l @@ -293,14 +293,14 @@ void zconf_initscan(const char *name) void zconf_nextfile(const char *name) { - struct file *file = file_lookup(name); + struct file *file = file_lookup(conf_expand_value(name)); struct buffer *buf = malloc(sizeof(*buf)); memset(buf, 0, sizeof(*buf)); current_buf->state = YY_CURRENT_BUFFER; - yyin = zconf_fopen(name); + yyin = zconf_fopen(file->name); if (!yyin) { - printf("%s:%d: can't open file \"%s\"\n", zconf_curname(), zconf_lineno(), name); + printf("%s:%d: can't open file \"%s\"\n", zconf_curname(), zconf_lineno(), file->name); exit(1); } yy_switch_to_buffer(yy_create_buffer(yyin, YY_BUF_SIZE)); @@ -308,11 +308,11 @@ void zconf_nextfile(const char *name) current_buf = buf; if (file->flags & FILE_BUSY) { - printf("recursive scan (%s)?\n", name); + printf("recursive scan (%s)?\n", file->name); exit(1); } if (file->flags & FILE_SCANNED) { - printf("file %s already scanned?\n", name); + printf("file %s already scanned?\n", file->name); exit(1); } file->flags |= FILE_BUSY; ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ kbuild-devel mailing list kbuild-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kbuild-devel