diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2007-07-20 18:00:36 -0400 |
---|---|---|
committer | Sam Ravnborg <sam@ravnborg.org> | 2007-07-25 15:14:26 -0400 |
commit | 03d29122738f0bd81afd44b1f566e64ebf8d06fe (patch) | |
tree | 10038c037b7b82577fec387fa6cd8042fc8633e7 /scripts/kconfig/zconf.y | |
parent | 4a645d5ea65baaa5736bcb566673bf4a351b2ad8 (diff) |
kconfig: attach help text to menus
Roman Zippel wrote:
> A simple example would be
> help texts, right now they are per symbol, but they should really be per
> menu, so archs can provide different help texts for something.
This patch does this and at the same time introduce a few API
funtions used to access the help text.
The relevant api functions are introduced in the various frontends.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Diffstat (limited to 'scripts/kconfig/zconf.y')
-rw-r--r-- | scripts/kconfig/zconf.y | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/scripts/kconfig/zconf.y b/scripts/kconfig/zconf.y index 92eb02bdf9c5..79db4cf22a51 100644 --- a/scripts/kconfig/zconf.y +++ b/scripts/kconfig/zconf.y | |||
@@ -402,7 +402,7 @@ help_start: T_HELP T_EOL | |||
402 | 402 | ||
403 | help: help_start T_HELPTEXT | 403 | help: help_start T_HELPTEXT |
404 | { | 404 | { |
405 | current_entry->sym->help = $2; | 405 | current_entry->help = $2; |
406 | }; | 406 | }; |
407 | 407 | ||
408 | /* depends option */ | 408 | /* depends option */ |
@@ -649,11 +649,11 @@ void print_symbol(FILE *out, struct menu *menu) | |||
649 | break; | 649 | break; |
650 | } | 650 | } |
651 | } | 651 | } |
652 | if (sym->help) { | 652 | if (menu->help) { |
653 | int len = strlen(sym->help); | 653 | int len = strlen(menu->help); |
654 | while (sym->help[--len] == '\n') | 654 | while (menu->help[--len] == '\n') |
655 | sym->help[len] = 0; | 655 | menu->help[len] = 0; |
656 | fprintf(out, " help\n%s\n", sym->help); | 656 | fprintf(out, " help\n%s\n", menu->help); |
657 | } | 657 | } |
658 | fputc('\n', out); | 658 | fputc('\n', out); |
659 | } | 659 | } |