Changeset 3683


Ignore:
Timestamp:
2006-04-20T23:00:14+02:00 (12 years ago)
Author:
nbd
Message:

modify the kconfig system for openwrt

Location:
branches/buildroot-ng/openwrt/scripts/config
Files:
1 added
8 edited

Legend:

Unmodified
Added
Removed
  • branches/buildroot-ng/openwrt/scripts/config/Makefile

    r3682 r3683  
    11# =========================================================================== 
    2 # Kernel configuration targets 
     2# OpenWrt configuration targets 
    33# These targets are used from top-level makefile 
    44 
     
    4141 
    4242%.tab.c: %.y 
    43         bison -l -b $* -p $(notdir $*) $< && cp $@ $@_shipped || cp $@_shipped $@ 
     43        cp $@_shipped $@ || bison -l -b $* -p $(notdir $*) $< 
    4444 
    4545lex.%.c: %.l 
    46         flex -L -P$(notdir $*) -o$@ $< && cp $@ $@_shipped || cp $@_shipped $@ 
     46        cp $@_shipped $@ || flex -L -P$(notdir $*) -o$@ $< 
    4747 
    4848%.hash.c: %.gperf 
    49         gperf < $< > $@ && cp $@ $@_shipped || cp $@_shipped $@ 
     49        cp $@_shipped $@ || gperf < $< > $@ 
  • branches/buildroot-ng/openwrt/scripts/config/conf.c

    r3682 r3683  
    571571                if (stat(".config", &tmpstat)) { 
    572572                        printf(_("***\n" 
    573                                 "*** You have not yet configured your kernel!\n" 
     573                                "*** You have not yet configured your build!\n" 
    574574                                "***\n" 
    575575                                "*** Please run some configurator (e.g. \"make oldconfig\" or\n" 
     
    620620        } while (conf_cnt); 
    621621        if (conf_write(NULL)) { 
    622                 fprintf(stderr, _("\n*** Error during writing of the kernel configuration.\n\n")); 
     622                fprintf(stderr, _("\n*** Error during writing of the build configuration.\n\n")); 
    623623                return 1; 
    624624        } 
  • branches/buildroot-ng/openwrt/scripts/config/confdata.c

    r3682 r3683  
    2323const char conf_def_filename[] = ".config"; 
    2424 
    25 const char conf_defname[] = "arch/$ARCH/defconfig"; 
     25const char conf_defname[] = "scripts/config/defconfig"; 
    2626 
    2727const char *conf_confnames[] = { 
    2828        ".config", 
    29         "/lib/modules/$UNAME_RELEASE/.config", 
    30         "/etc/kernel-config", 
    31         "/boot/config-$UNAME_RELEASE", 
    3229        conf_defname, 
    3330        NULL, 
     
    376373                        return 1; 
    377374        } 
    378         sym = sym_lookup("KERNELVERSION", 0); 
     375        sym = sym_lookup("OPENWRTVERSION", 0); 
    379376        sym_calc_value(sym); 
    380377        time(&now); 
     
    385382        fprintf(out, _("#\n" 
    386383                       "# Automatically generated make config: don't edit\n" 
    387                        "# Linux kernel version: %s\n" 
     384                       "# OpenWrt version: %s\n" 
    388385                       "%s%s" 
    389386                       "#\n"), 
     
    394391                fprintf(out_h, "/*\n" 
    395392                               " * Automatically generated C config: don't edit\n" 
    396                                " * Linux kernel version: %s\n" 
     393                               " * OpenWrt version: %s\n" 
    397394                               "%s%s" 
    398395                               " */\n" 
     
    429426                        if (type == S_TRISTATE) { 
    430427                                sym_calc_value(modules_sym); 
     428/* tristate always enabled */ 
     429#if 0 
    431430                                if (modules_sym->curr.tri == no) 
    432431                                        type = S_BOOLEAN; 
     432#endif 
    433433                        } 
    434434                        switch (type) { 
  • branches/buildroot-ng/openwrt/scripts/config/mconf.c

    r3682 r3683  
    3030"Overview\n" 
    3131"--------\n" 
    32 "Some kernel features may be built directly into the kernel.\n" 
    33 "Some may be made into loadable runtime modules.  Some features\n" 
    34 "may be completely removed altogether.  There are also certain\n" 
    35 "kernel parameters which are not really features, but must be\n" 
    36 "entered in as decimal or hexadecimal numbers or possibly text.\n" 
     32"Some OpenWrt features may be built directly into the image.\n" 
     33"Some may be made into installable ipkg packages. Some features\n" 
     34"may be completely removed altogether.\n" 
    3735"\n" 
    3836"Menu items beginning with [*], <M> or [ ] represent features\n" 
     
    116114"Menuconfig supports the use of alternate configuration files for\n" 
    117115"those who, for various reasons, find it necessary to switch\n" 
    118 "between different kernel configurations.\n" 
     116"between different OpenWrt configurations.\n" 
    119117"\n" 
    120118"At the end of the main menu you will find two options.  One is\n" 
     
    149147"Optional personality available\n" 
    150148"------------------------------\n" 
    151 "If you prefer to have all of the kernel options listed in a single\n" 
     149"If you prefer to have all of the build options listed in a single\n" 
    152150"menu, rather than the default multimenu hierarchy, run the menuconfig\n" 
    153151"with MENUCONFIG_MODE environment variable set to single_menu. Example:\n" 
     
    187185        "As a result, this feature will be built as a module."), 
    188186nohelp_text[] = N_( 
    189         "There is no help available for this kernel option.\n"), 
     187        "There is no help available for this config option.\n"), 
    190188load_config_text[] = N_( 
    191189        "Enter the name of the configuration file you wish to load.  " 
     
    194192load_config_help[] = N_( 
    195193        "\n" 
    196         "For various reasons, one may wish to keep several different kernel\n" 
     194        "For various reasons, one may wish to keep several different OpenWrt\n" 
    197195        "configurations available on a single machine.\n" 
    198196        "\n" 
    199         "If you have saved a previous configuration in a file other than the\n" 
    200         "kernel's default, entering the name of the file here will allow you\n" 
     197        "If you have saved a previous configuration in a file other than\n" 
     198        "OpenWrt's default, entering the name of the file here will allow you\n" 
    201199        "to modify that configuration.\n" 
    202200        "\n" 
     
    208206save_config_help[] = N_( 
    209207        "\n" 
    210         "For various reasons, one may wish to keep different kernel\n" 
     208        "For various reasons, one may wish to keep different OpenWrt\n" 
    211209        "configurations available on a single machine.\n" 
    212210        "\n" 
     
    10521050        conf_read(NULL); 
    10531051 
    1054         sym = sym_lookup("KERNELVERSION", 0); 
     1052        sym = sym_lookup("OPENWRTVERSION", 0); 
    10551053        sym_calc_value(sym); 
    1056         sprintf(menu_backtitle, _("Linux Kernel v%s Configuration"), 
     1054        sprintf(menu_backtitle, _("OpenWrt %s Configuration"), 
    10571055                sym_get_string_value(sym)); 
    10581056 
     
    10711069                cprint_init(); 
    10721070                cprint("--yesno"); 
    1073                 cprint(_("Do you wish to save your new kernel configuration?")); 
     1071                cprint(_("Do you wish to save your new OpenWrt configuration?")); 
    10741072                cprint("5"); 
    10751073                cprint("60"); 
     
    10801078                if (conf_write(NULL)) { 
    10811079                        fprintf(stderr, _("\n\n" 
    1082                                 "Error during writing of the kernel configuration.\n" 
    1083                                 "Your kernel configuration changes were NOT saved." 
     1080                                "Error during writing of the OpenWrt configuration.\n" 
     1081                                "Your configuration changes were NOT saved." 
    10841082                                "\n\n")); 
    10851083                        return 1; 
    10861084                } 
    10871085                printf(_("\n\n" 
    1088                         "*** End of Linux kernel configuration.\n" 
    1089                         "*** Execute 'make' to build the kernel or try 'make help'." 
     1086                        "*** End of OpenWrt configuration.\n" 
     1087                        "*** Execute 'make' to build the OpenWrt or try 'make help'." 
    10901088                        "\n\n")); 
    10911089        } else { 
    10921090                fprintf(stderr, _("\n\n" 
    1093                         "Your kernel configuration changes were NOT saved." 
     1091                        "Your configuration changes were NOT saved." 
    10941092                        "\n\n")); 
    10951093        } 
  • branches/buildroot-ng/openwrt/scripts/config/menu.c

    r3682 r3683  
    8989                e->right.expr = menu_check_dep(e->right.expr); 
    9090                break; 
     91/* tristate always enabled */ 
     92#if 0 
    9193        case E_SYMBOL: 
    9294                /* change 'm' into 'm' && MODULES */ 
     
    9496                        return expr_alloc_and(e, expr_alloc_symbol(modules_sym)); 
    9597                break; 
     98#endif 
    9699        default: 
    97100                break; 
  • branches/buildroot-ng/openwrt/scripts/config/symbol.c

    r3682 r3683  
    6262                sym_add_default(sym, p); 
    6363 
    64         sym = sym_lookup("KERNELVERSION", 0); 
     64        sym = sym_lookup("OPENWRTVERSION", 0); 
    6565        sym->type = S_STRING; 
    6666        sym->flags |= SYMBOL_AUTO; 
    67         p = getenv("KERNELVERSION"); 
     67        p = getenv("OPENWRTVERSION"); 
    6868        if (p) 
    6969                sym_add_default(sym, p); 
     
    8282                if (sym_is_choice_value(sym) && sym->visible == yes) 
    8383                        type = S_BOOLEAN; 
     84/* tristate always enabled */ 
     85#if 0 
    8486                else if (modules_val == no) 
    8587                        type = S_BOOLEAN; 
     88#endif 
    8689        } 
    8790        return type; 
     
    202205                tri = E_OR(tri, prop->visible.tri); 
    203206        } 
     207/* tristate always enabled */ 
     208#if 0 
    204209        if (tri == mod && (sym->type != S_TRISTATE || modules_val == no)) 
     210#else 
     211        if (tri == mod && (sym->type != S_TRISTATE)) 
     212#endif 
    205213                tri = yes; 
    206214        if (sym->visible != tri) { 
     
    355363        if (memcmp(&oldval, &sym->curr, sizeof(oldval))) 
    356364                sym_set_changed(sym); 
     365 
    357366        if (modules_sym == sym) 
    358367                modules_val = modules_sym->curr.tri; 
  • branches/buildroot-ng/openwrt/scripts/config/zconf.tab.c_shipped

    r3682 r3683  
    19271927        menu_init(); 
    19281928        modules_sym = sym_lookup("MODULES", 0); 
    1929         rootmenu.prompt = menu_add_prompt(P_MENU, "Linux Kernel Configuration", NULL); 
     1929        rootmenu.prompt = menu_add_prompt(P_MENU, "OpenWrt Configuration", NULL); 
    19301930 
    19311931#if YYDEBUG 
  • branches/buildroot-ng/openwrt/scripts/config/zconf.y

    r3682 r3683  
    460460        menu_init(); 
    461461        modules_sym = sym_lookup("MODULES", 0); 
    462         rootmenu.prompt = menu_add_prompt(P_MENU, "Linux Kernel Configuration", NULL); 
     462        rootmenu.prompt = menu_add_prompt(P_MENU, "OpenWrt Configuration", NULL); 
    463463 
    464464#if YYDEBUG 
Note: See TracChangeset for help on using the changeset viewer.