From 4b3e11b3e7d00881878f45cddbfe8f4bf07d1ebe Mon Sep 17 00:00:00 2001 From: Alper Yildirim Date: Mon, 20 Jul 2009 18:50:58 +0200 Subject: config: Update package/config to Kconfig 2.6.30 Update the package/config stuff with the code available in the Linux kernel 2.6.30. Signed-off-by: Alper Yildirim --- package/config/zconf.l | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'package/config/zconf.l') diff --git a/package/config/zconf.l b/package/config/zconf.l index 4a0447b9e..21ff69c9a 100644 --- a/package/config/zconf.l +++ b/package/config/zconf.l @@ -1,5 +1,6 @@ %option backup nostdinit noyywrap never-interactive full ecs %option 8bit backup nodefault perf-report perf-report +%option noinput %x COMMAND HELP STRING PARAM %{ /* @@ -49,11 +50,6 @@ void new_string(void) void append_string(const char *str, int size) { int new_size = text_size + size + 1; - - if ((YY_START == 2 /* HELP */) && (size > 70)) { - fprintf (stderr, "%s:%d warning: Overlong line\n", - current_file->name, current_file->lineno); - } if (new_size > text_asize) { new_size += START_STRSIZE - 1; new_size &= -START_STRSIZE; @@ -222,6 +218,11 @@ n [A-Za-z0-9_] append_string("\n", 1); } [^ \t\n].* { + while (yyleng) { + if ((yytext[yyleng-1] != ' ') && (yytext[yyleng-1] != '\t')) + break; + yyleng--; + } append_string(yytext, yyleng); if (!first_ts) first_ts = last_ts; @@ -313,11 +314,14 @@ void zconf_nextfile(const char *name) current_buf = buf; if (file->flags & FILE_BUSY) { - printf("recursive scan (%s)?\n", name); + printf("%s:%d: do not source '%s' from itself\n", + zconf_curname(), zconf_lineno(), name); exit(1); } if (file->flags & FILE_SCANNED) { - printf("file %s already scanned?\n", name); + printf("%s:%d: file '%s' is already sourced from '%s'\n", + zconf_curname(), zconf_lineno(), name, + file->parent->name); exit(1); } file->flags |= FILE_BUSY; -- cgit v1.2.3-55-g7522