diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-26 11:05:15 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-26 11:05:15 -0700 |
commit | 2a2ed2db353d949c06b6ef8b6913f65b39111eab (patch) | |
tree | d835c3dd101da91089c3bdf51c8632e84be37232 /scripts/kconfig/zconf.y | |
parent | 972d19e837833b93466c6f6a8ef2a7d653000aa3 (diff) | |
parent | 070b98bfda3d27269519067c1c67eaef695f3e0c (diff) | |
download | linux-2a2ed2db353d949c06b6ef8b6913f65b39111eab.tar.bz2 |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild: (40 commits)
kbuild: trivial fixes in Makefile
kbuild: adding symbols in Kconfig and defconfig to TAGS
kbuild: replace abort() with exit(1)
kbuild: support for %.symtypes files
kbuild: fix silentoldconfig recursion
kbuild: add option for stripping modules while installing them
kbuild: kill some false positives from modpost
kbuild: export-symbol usage report generator
kbuild: fix make -rR breakage
kbuild: append -dirty for updated but uncommited changes
kbuild: append git revision for all untagged commits
kbuild: fix module.symvers parsing in modpost
kbuild: ignore make's built-in rules & variables
kbuild: bugfix with initramfs
kbuild: modpost build fix
kbuild: check license compatibility when building modules
kbuild: export-type enhancement to modpost.c
kbuild: add dependency on kernel.release to the package targets
kbuild: `make kernelrelease' speedup
kconfig: KCONFIG_OVERWRITECONFIG
...
Diffstat (limited to 'scripts/kconfig/zconf.y')
-rw-r--r-- | scripts/kconfig/zconf.y | 33 |
1 files changed, 32 insertions, 1 deletions
diff --git a/scripts/kconfig/zconf.y b/scripts/kconfig/zconf.y index 1f61fba6aa28..ab44feb3c600 100644 --- a/scripts/kconfig/zconf.y +++ b/scripts/kconfig/zconf.y @@ -71,6 +71,7 @@ static struct menu *current_menu, *current_entry; %token <id>T_DEFAULT %token <id>T_SELECT %token <id>T_RANGE +%token <id>T_OPTION %token <id>T_ON %token <string> T_WORD %token <string> T_WORD_QUOTE @@ -91,6 +92,7 @@ static struct menu *current_menu, *current_entry; %type <id> end %type <id> option_name %type <menu> if_entry menu_entry choice_entry +%type <string> symbol_option_arg %destructor { fprintf(stderr, "%s:%d: missing end statement for this entry\n", @@ -173,6 +175,7 @@ menuconfig_stmt: menuconfig_entry_start config_option_list config_option_list: /* empty */ | config_option_list config_option + | config_option_list symbol_option | config_option_list depends | config_option_list help | config_option_list option_error @@ -215,6 +218,26 @@ config_option: T_RANGE symbol symbol if_expr T_EOL printd(DEBUG_PARSE, "%s:%d:range\n", zconf_curname(), zconf_lineno()); }; +symbol_option: T_OPTION symbol_option_list T_EOL +; + +symbol_option_list: + /* empty */ + | symbol_option_list T_WORD symbol_option_arg +{ + struct kconf_id *id = kconf_id_lookup($2, strlen($2)); + if (id && id->flags & TF_OPTION) + menu_add_option(id->token, $3); + else + zconfprint("warning: ignoring unknown option %s", $2); + free($2); +}; + +symbol_option_arg: + /* empty */ { $$ = NULL; } + | T_EQUAL prompt { $$ = $2; } +; + /* choice entry */ choice: T_CHOICE T_EOL @@ -458,7 +481,9 @@ void conf_parse(const char *name) sym_init(); menu_init(); - modules_sym = sym_lookup("MODULES", 0); + modules_sym = sym_lookup(NULL, 0); + modules_sym->type = S_BOOLEAN; + modules_sym->flags |= SYMBOL_AUTO; rootmenu.prompt = menu_add_prompt(P_MENU, "Linux Kernel Configuration", NULL); #if YYDEBUG @@ -468,6 +493,12 @@ void conf_parse(const char *name) zconfparse(); if (zconfnerrs) exit(1); + if (!modules_sym->prop) { + struct property *prop; + + prop = prop_alloc(P_DEFAULT, modules_sym); + prop->expr = expr_alloc_symbol(sym_lookup("MODULES", 0)); + } menu_finalize(&rootmenu); for_all_symbols(i, sym) { sym_check_deps(sym); |