同步操作将从 Gitee 极速下载/MiniGUI 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
#! /bin/sh## This script is used to configure the MiniGUI library.# Borrowed from linux kernel configuration scripts.## This script attempts to parse the configuration files, which are# scattered throughout the source tree, and creates a temporary# set of mini scripts which are in turn used to create nested menus and# radiolists.## It uses a very modified/mutilated version of the "dialog" utility# written by Savio Lam (lam836@cs.cuhk.hk). Savio is not responsible# for this script or the version of dialog used by this script.# Please do not contact him with questions. The official version of# dialog is available at sunsite.unc.edu or a sunsite mirror.### Change this to TRUE if you prefer all configure options listed# in a single menu rather than the standard menu hierarchy.#single_menu_mode=## Make sure we're really running bash.#[ -z "$BASH" ] && { echo "Menuconfig requires bash" 1>&2; exit 1; }## Cache function definitions, turn off posix compliance#set -h +o posix# Given a configuration variable, set the global variable $x to its value,# and the global variable $info to the string " (NEW)" if this is a new# variable.## This function looks for: (1) the current value, or (2) the default value# from the arch-dependent defconfig file, or (3) a default passed by the caller.function set_x_info () {eval x=\$1ドルif [ -z "$x" ]; theneval `sed -n -e 's/# \(.*\) is not set.*/1円=n/' -e "/^1ドル=/p" arch/$ARCH/defconfig`eval x=\${1ドル:-\"2ドル\"}eval 1ドル=$x#eval INFO_1ドル="' (NEW)'"fieval info=\"\$INFO_1ドル\"}## Load the functions used by the config.in files.## I do this because these functions must be redefined depending# on whether they are being called for interactive use or for# saving a configuration to a file.## Thank the heavens bash supports nesting function definitions.#load_functions () {## Additional comments#function comment () {comment_ctr=$[ comment_ctr + 1 ]echo -ne "': $comment_ctr' '--- 1ドル' " >>MCmenu}## Define a boolean to a specific value.#function define_bool () {eval 1ドル=2ドル}function define_tristate () {eval 1ドル=2ドル}function define_hex () {eval 1ドル=2ドル}function define_int () {eval 1ドル=2ドル}function define_string () {eval 1ドル=\"2ドル\"}function define_mystring () {eval 1ドル=2ドル}function define_mystring_null () {eval 1ドル=2ドル}## Create a boolean (Yes/No) function for our current menu# which calls our local bool function.#function bool () {set_x_info "2ドル" "n"case $x iny|m) flag="*" ;;n) flag=" " ;;esacecho -ne "'2ドル' '[$flag] 1ドル$info' " >>MCmenuecho -e "function 2ドル () { l_bool '2ドル' \"\$1\" ;}\n" >>MCradiolists}## Create a tristate (Yes/No/Module) radiolist function# which calls our local tristate function.## Collapses to a boolean (Yes/No) if module support is disabled.#function tristate () {if [ "$CONFIG_MODULES" != "y" ]thenbool "1ドル" "2ドル"elseset_x_info "2ドル" "n"case $x iny) flag="*" ;;m) flag="M" ;;*) flag=" " ;;esacecho -ne "'2ドル' '<$flag> 1ドル$info' " >>MCmenuecho -e "function 2ドル () { l_tristate '2ドル' \"\$1\" ;}" >>MCradiolistsfi}## Create a tristate radiolist function which is dependent on# another MiniGUI configuration option.## Quote from the original configure script:##function dep_tristate () {ques="1ドル"var="2ドル"dep=yshift 2while [ $# -gt 0 ]; doif [ "1ドル" = y ]; thenshiftelif [ "1ドル" = m ]; thendep=mshiftelsedep=nshift $#fidoneif [ "$dep" = y ]; thentristate "$ques" "$var"elif [ "$dep" = m ]; thenmod_bool "$ques" "$var"elsedefine_tristate "$var" nfi}## Same as above, but now only Y and N are allowed as dependency# (i.e. third and next arguments).#function dep_bool () {ques="1ドル"var="2ドル"dep=yshift 2while [ $# -gt 0 ]; doif [ "1ドル" = y ]; thenshiftelsedep=nshift $#fidoneif [ "$dep" = y ]; thenbool "$ques" "$var"elsedefine_bool "$var" nfi}function dep_mbool () {ques="1ドル"var="2ドル"dep=yshift 2while [ $# -gt 0 ]; doif [ "1ドル" = y -o "1ドル" = m ]; thenshiftelsedep=nshift $#fidoneif [ "$dep" = y ]; thenbool "$ques" "$var"elsedefine_bool "$var" nfi}## Add a menu item which will call our local int function.#function int () {set_x_info "2ドル" "3ドル"echo -ne "'2ドル' '($x) 1ドル$info' " >>MCmenuecho -e "function 2ドル () { l_int '1ドル' '2ドル' '3ドル' '$x' ;}" >>MCradiolists}## Add a menu item which will call our local hex function.#function hex () {set_x_info "2ドル" "3ドル"x=${x##*[x,X]}echo -ne "'2ドル' '($x) 1ドル$info' " >>MCmenuecho -e "function 2ドル () { l_hex '1ドル' '2ドル' '3ドル' '$x' ;}" >>MCradiolists}## Add a menu item which will call our local string function.#function string () {set_x_info "2ドル" "3ドル"echo -ne "'2ドル' ' 1ドル: \"$x\"$info' " >>MCmenuecho -e "function 2ドル () { l_string '1ドル' '2ドル' '3ドル' '$x' ;}" >>MCradiolists}function mystring () {set_x_info "2ドル" "3ドル"echo -ne "'2ドル' ' 1ドル: \"$x\"$info' " >>MCmenuecho -e "function 2ドル () { l_string '1ドル' '2ドル' '3ドル' '$x' ;}" >>MCradiolists}## Add a menu item which will call our local One-of-Many choice list.#function choice () {## Need to remember params cause they're gonna get reset.#title=1ドルchoices=2ドルdefault=3ドルcurrent=## Find out if one of the choices is already set.# If it's not then make it the default.#set -- $choicesfirstchoice=2ドルwhile [ -n "2ドル" ]doif eval [ \"_\$2ドル\" = \"_y\" ]thencurrent=1ドルbreakfishift ; shiftdone: ${current:=$default}echo -ne "'$firstchoice' '($current) $title' " >>MCmenuecho -e "function $firstchoice () \{ l_choice '$title' \"$choices\"\"$current\" ;}" >>MCradiolists}} # END load_functions()function configure_help () {if [ "$CONFIG_HELP_CHN" = "y" ]; thenCONFIGURE_HELPFILE=configs/Configure-zh.helpelseCONFIGURE_HELPFILE=configs/Configure.helpfi}## Extract available help for an option from Configure.help# and send it to standard output.## Most of this function was borrowed from the original kernel# Configure script.#function extract_help () {configure_helpif [ -f $CONFIGURE_HELPFILE ]then#first escape regexp special characters in the argument:var=$(echo "1ドル"|sed 's/[][\/.^$*]/\\&/g')#now pick out the right help text:text=$(sed -n "/^$var[ ]*\$/,\${/^$var[ ]*\$/c\\${var}:\\/^#/b/^[^ ]/qs/^ ///<file:\\([^>]*\\)>/s//\\1/gp}" $CONFIGURE_HELPFILE )if [ -z "$text" ]thenecho "There is no help available for this MiniGUI configure option."return 1elseecho "$text"fielseecho "There is no help available for this MiniGUI configure option."return 1fi}## Activate a help dialog.#function help () {if extract_help 1ドル >help.outthen$DIALOG --backtitle "$backtitle" --title "2ドル"\--textbox help.out $ROWS $COLSelse$DIALOG --backtitle "$backtitle" \--textbox help.out $ROWS $COLSfirm -f help.out}## Show the README file.#function show_readme () {$DIALOG --backtitle "$backtitle" \--textbox scripts/README.Menuconfig $ROWS $COLS}## Begin building the dialog menu command and Initialize the# Radiolist function file.#function menu_name () {echo -ne "$DIALOG --title '1ドル'\--backtitle '$backtitle' \--menu '$menu_instructions' \$ROWS$COLS$((ROWS-10))\'$default' " >MCmenu>MCradiolists}## Add a submenu option to the menu currently under construction.#function submenu () {echo -ne "'activate_menu 2ドル' '1ドル --->' " >>MCmenu}## Handle a boolean (Yes/No) option.#function l_bool () {if [ -n "2ドル" ]thencase "2ドル" iny|m) eval 1ドル=y ;;c) eval x=\$1ドルcase $x iny) eval 1ドル=n ;;n) eval 1ドル=y ;;*) eval 1ドル=y ;;esac ;;*) eval 1ドル=n ;;esacelseecho -ne "0円07"fi}## Same as bool() except options are (Module/No)#function mod_bool () {if [ "$CONFIG_MODULES" != "y" ]; thendefine_bool "2ドル" "n"elseset_x_info "2ドル" "n"case $x iny|m) flag='M' ;;*) flag=' ' ;;esacecho -ne "'2ドル' '<$flag> 1ドル$info' " >>MCmenuecho -e "function 2ドル () { l_mod_bool '2ドル' \"\$1\" ;}" >>MCradiolistsfi}## Same as l_bool() except options are (Module/No)#function l_mod_bool() {if [ -n "2ドル" ]thencase "2ドル" iny) echo -en "0円07"${DIALOG} --backtitle "$backtitle" \--infobox "\This feature depends on another which has been configured as a module. \As a result, this feature will be built as a module." 4 70sleep 5eval 1ドル=m ;;m) eval 1ドル=m ;;c) eval x=\$1ドルcase $x inm) eval 1ドル=n ;;n) eval 1ドル=m ;;*) eval 1ドル=m ;;esac ;;*) eval 1ドル=n ;;esacelseecho -ne "0円07"fi}## Handle a tristate (Yes/No/Module) option.#function l_tristate () {if [ -n "2ドル" ]theneval x=\$1ドルcase "2ドル" iny) eval 1ドル=y ;;m) eval 1ドル=m ;;c) eval x=\$1ドルcase $x iny) eval 1ドル=n ;;n) eval 1ドル=m ;;m) eval 1ドル=y ;;*) eval 1ドル=y ;;esac ;;*) eval 1ドル=n ;;esacelseecho -ne "0円07"fi}## Create a dialog for entering an integer into a option.#function l_int () {while truedoif $DIALOG --title "1ドル" \--backtitle "$backtitle" \--inputbox "$inputbox_instructions_int" \10 75 "4ドル" 2>MCdialog.outthenanswer="`cat MCdialog.out`"answer="${answer:-3ドル}"# Semantics of + and ? in GNU expr changed, so# we avoid them:if expr "$answer" : '0$' '|' "$answer" : '[1-9][0-9]*$' '|' "$answer" : '-[1-9][0-9]*$' >/dev/nulltheneval 2ドル=\"$answer\"elseeval 2ドル=\"3ドル\"echo -en "0円07"${DIALOG} --backtitle "$backtitle" \--infobox "You have made an invalid entry." 3 43sleep 2fibreakfihelp "2ドル" "1ドル"done}## Create a dialog for entering a hexadecimal into a option.#function l_hex () {while truedoif $DIALOG --title "1ドル" \--backtitle "$backtitle" \--inputbox "$inputbox_instructions_hex" \10 75 "4ドル" 2>MCdialog.outthenanswer="`cat MCdialog.out`"answer="${answer:-3ドル}"answer="${answer##*[x,X]}"if expr "$answer" : '[0-9a-fA-F][0-9a-fA-F]*$' >/dev/nulltheneval 2ドル=\"$answer\"elseeval 2ドル=\"3ドル\"echo -en "0円07"${DIALOG} --backtitle "$backtitle" \--infobox "You have made an invalid entry." 3 43sleep 2fibreakfihelp "2ドル" "1ドル"done}## Create a dialog for entering a string into a option.#function l_string () {while truedoif $DIALOG --title "1ドル" \--backtitle "$backtitle" \--inputbox "$inputbox_instructions_string" \10 75 "4ドル" 2>MCdialog.outthenanswer="`cat MCdialog.out`"answer="${answer:-3ドル}"## Someone may add a nice check for the entered# string here...#eval 2ドル=\"$answer\"breakfihelp "2ドル" "1ドル"done}## Handle a one-of-many choice list.#function l_choice () {## Need to remember params cause they're gonna get reset.#title="1ドル"choices="2ドル"current="3ドル"chosen=## Scan current value of choices and set radiolist switches.#list=set -- $choicesfirstchoice=2ドルwhile [ -n "2ドル" ]docase "1ドル" in"$current"*) if [ -z "$chosen" ]; thenlist="$list2ドル1ドル ON "chosen=1elselist="$list2ドル1ドル OFF "fi ;;*) list="$list2ドル1ドル OFF " ;;esacshift ; shiftdonewhile truedoif $DIALOG --title "$title" \--backtitle "$backtitle" \--radiolist "$radiolist_instructions" \15 70 6 $list 2>MCdialog.outthenchoice=`cat MCdialog.out`breakfihelp "$firstchoice" "$title"done## Now set the boolean value of each option based on# the selection made from the radiolist.#set -- $choiceswhile [ -n "2ドル" ]doif [ "2ドル" = "$choice" ]theneval 2ドル=\"y\"elseeval 2ドル=\"n\"fishift ; shiftdone}## Call awk, and watch for error codes, etc.#function callawk () {awk "1ドル" || { echo "Awk died with error code $?. Giving up."; exit 1; }}## A faster awk based recursive parser. (I hope)#function parser1 () {callawk 'BEGIN {menu_no = 0comment_is_option = 0parser("'$CONFIG_IN'","MCmenu0")}function parser(ifile,menu) {while (getline <ifile) {if (1ドル == "mainmenu_option") {comment_is_option = "1"}else if (1ドル == "comment" && comment_is_option == "1") {comment_is_option= "0"sub(1,ドル"",0ドル)++menu_noprintf("submenu %s MCmenu%s\n", 0,ドル menu_no) >>menunewmenu = sprintf("MCmenu%d", menu_no);printf( "function MCmenu%s () {\n"\"default=1ドル\n"\"menu_name %s\n",\menu_no, 0ドル) >newmenuparser(ifile, newmenu)}else if (0ドル ~ /^#|\$MAKE|mainmenu_name/) {printf("") >>menu}else if (1ドル ~ "endmenu") {printf("}\n") >>menureturn}else if (1ドル == "source") {parser(2,ドルmenu)}else {print >>menu}}}'}## Secondary parser for single menu mode.#function parser2 () {callawk 'BEGIN {parser("'$CONFIG_IN'","MCmenu0")}function parser(ifile,menu) {while (getline <ifile) {if (0ドル ~ /^#|$MAKE|mainmenu_name/) {printf("") >>menu}else if (1ドル ~ /mainmenu_option|endmenu/) {printf("") >>menu}else if (1ドル == "source") {parser(2,ドルmenu)}else {print >>menu}}}'}## Parse all the config.in files into mini scripts.#function parse_config_files () {rm -f MCmenu*echo "function MCmenu0 () {" >MCmenu0echo 'default=1ドル' >>MCmenu0echo "menu_name 'Main Menu'" >>MCmenu0if [ "_$single_menu_mode" = "_TRUE" ]thenparser2elseparser1fiecho "comment ''" >>MCmenu0echo "g_alt_config" >>MCmenu0echo "s_alt_config" >>MCmenu0echo "}" >>MCmenu0## These mini scripts must be sourced into the current# environment in order for all of this to work. Leaving# them on the disk as executables screws up the recursion# in activate_menu(), among other things. Once they are# sourced we can discard them.#for i in MCmenu*doecho -n "."source ./$idonerm -f MCmenu*}## This is the menu tree's bootstrap.## Executes the parsed menus on demand and creates a set of functions,# one per configuration option. These functions will in turn execute# dialog commands or recursively call other menus.#function activate_menu () {rm -f lxdialog.scrltmpwhile truedocomment_ctr=0 #So comment lines get unique tags1ドル "$default" 2> MCerror #Create the lxdialog menu & functionsif [ "$?" != "0" ]thenclearcat <<EOMMenuconfig has encountered a possible error in one of the MiniGUI'sconfiguration files and is unable to continue. Here is the errorreport:EOMsed 's/^/ Q> /' MCerrorcat <<EOMPlease report this to the maintainer <mec@shout.net>. You may alsosend a problem report to <linux-kernel@vger.kernel.org>.Please indicate the kernel version you are trying to configure andwhich menu you were trying to enter when this error occurred.EOMcleanupexit 1firm -f MCerror. ./MCradiolists #Source the menu's functions. ./MCmenu 2>MCdialog.out #Activate the lxdialog menuret=$?read selection <MCdialog.outcase "$ret" in0|3|4|5|6)defaults="$selection$defaults" #pseudo stackcase "$ret" in0) eval $selection ;;3) eval $selection y ;;4) eval $selection n ;;5) eval $selection m ;;6) eval $selection c ;;esacdefault="${defaults%%*}" defaults="${defaults#*}";;2)default="${selection%%\ *}"case "$selection" in*"-->"*|*"alt_config"*)show_readme ;;*)eval help $selection ;;esac;;255|1)break;;139)stty saneclearcat <<EOMThere seems to be a problem with the lxdialog companion utility which isbuilt prior to running Menuconfig. Usually this is an indicator that youhave upgraded/downgraded your ncurses libraries and did not remove theold ncurses header file(s) in /usr/include or /usr/include/ncurses.It is VERY important that you have only one set of ncurses header filesand that those files are properly version matched to the ncurses librariesinstalled on your machine.You may also need to rebuild lxdialog. This can be done by moving tothe /usr/src/linux/scripts/lxdialog directory and issuing the"make clean all" command.If you have verified that your ncurses install is correct, you may emailthe maintainer <mec@shout.net> or post a message to<linux-kernel@vger.kernel.org> for additional assistance.EOMcleanupexit 139;;esacdone}## Create a menu item to load an alternate configuration file.#g_alt_config () {echo -n "get_alt_config 'Load an Alternate Configuration File' "\>>MCmenu}## Get alternate config file name and load the# configuration from it.#get_alt_config () {set -f ## Switch file expansion OFFwhile truedoALT_CONFIG="${ALT_CONFIG:-$DEFAULTS}"$DIALOG --backtitle "$backtitle" \--inputbox "\Enter the name of the configuration file you wish to load. \Accept the name shown to restore the configuration you \last retrieved. Leave blank to abort."\11 55 "$ALT_CONFIG" 2>MCdialog.outif [ "$?" = "0" ]thenALT_CONFIG=`cat MCdialog.out`[ "_" = "_$ALT_CONFIG" ] && breakif eval [ -r \"$ALT_CONFIG\" ]theneval load_config_file \"$ALT_CONFIG\"breakelseecho -ne "0円07"$DIALOG --backtitle "$backtitle" \--infobox "File does not exist!" 3 38sleep 2fielsecat <<EOM >help.outFor various reasons, one may wish to keep several different MiniGUIconfigurations available on a single machine.If you have saved a previous configuration in a file other than thekernel's default, entering the name of the file here will allow youto modify that configuration.If you are uncertain, then you have probably never used alternateconfiguration files. You should therefor leave this blank to abort.EOM$DIALOG --backtitle "$backtitle"\--title "Load Alternate Configuration"\--textbox help.out $ROWS $COLSfidoneset +f ## Switch file expansion ONrm -f help.out MCdialog.out}## Create a menu item to store an alternate config file.#s_alt_config () {echo -n "save_alt_config 'Save Configuration to an Alternate File' "\>>MCmenu}## Get an alternate config file name and save the current# configuration to it.#save_alt_config () {set -f ## Switch file expansion OFFwhile truedo$DIALOG --backtitle "$backtitle" \--inputbox "\Enter a filename to which this configuration should be saved \as an alternate. Leave blank to abort."\10 55 "$ALT_CONFIG" 2>MCdialog.outif [ "$?" = "0" ]thenALT_CONFIG=`cat MCdialog.out`[ "_" = "_$ALT_CONFIG" ] && breakif eval touch $ALT_CONFIG 2>/dev/nulltheneval save_configuration $ALT_CONFIGload_functions ## RELOADbreakelseecho -ne "0円07"$DIALOG --backtitle "$backtitle" \--infobox "Can't create file! Probably a nonexistent directory." 3 60sleep 2fielsecat <<EOM >help.outFor various reasons, one may wish to keep different kernelconfigurations available on a single machine.Entering a file name here will allow you to later retrieve, modifyand use the current configuration as an alternate to whateverconfiguration options you have selected at that time.If you are uncertain what all this means then you should probablyleave this blank.EOM$DIALOG --backtitle "$backtitle"\--title "Save Alternate Configuration"\--textbox help.out $ROWS $COLSfidoneset +f ## Switch file expansion ONrm -f help.out MCdialog.out}## Load config options from a file.# Converts all "# OPTION is not set" lines to "OPTION=n" lines#function load_config_file () {awk '/# .* is not set.*/ { printf("%s=n\n", 2ドル) }! /# .* is not set.*/ { print }' 1ドル >.tmpconfigsource ./.tmpconfigrm -f .tmpconfig}## Just what it says.#save_configuration () {echoecho -n "Saving your MiniGUI configuration."## Now, let's redefine the configuration functions for final# output to the config files.## Nested function definitions, YIPEE!#function bool () {set_x_info "2ドル" "n"eval define_bool \"2ドル\" \"$x\"}function tristate () {set_x_info "2ドル" "n"eval define_tristate \"2ドル\" \"$x\"}function dep_tristate () {set_x_info "2ドル" "n"var="2ドル"shift 2while [ $# -gt 0 ]; doif [ "1ドル" = y ]; thenshiftelif [ "1ドル" = m -a "$x" != n ]; thenx=m; shiftelsex=n; shift $#fidonedefine_tristate "$var" "$x"}function dep_bool () {set_x_info "2ドル" "n"var="2ドル"shift 2while [ $# -gt 0 ]; doif [ "1ドル" = y ]; thenshiftelsex=n; shift $#fidonedefine_bool "$var" "$x"}function dep_mbool () {set_x_info "2ドル" "n"var="2ドル"shift 2while [ $# -gt 0 ]; doif [ "1ドル" = y -o "1ドル" = m ]; thenshiftelsex=n; shift $#fidonedefine_bool "$var" "$x"}function int () {set_x_info "2ドル" "3ドル"echo "2ドル=$x" >>$CONFIGecho "#define 2ドル ($x)" >>$CONFIG_H}function hex () {set_x_info "2ドル" "3ドル"echo "2ドル=$x" >>$CONFIGecho "#define 2ドル 0x${x##*[x,X]}" >>$CONFIG_H}function string () {set_x_info "2ドル" "3ドル"echo "2ドル=\"$x\"" >>$CONFIGecho "#define 2ドル\"$x\"" >>$CONFIG_H}function mystring () {set_x_info "2ドル" "3ドル"echo "2ドル=$x" >>$CONFIGecho "#define 2ドル$x" >>$CONFIG_H}function define_hex () {eval 1ドル=\"2ドル\"echo "1ドル=2ドル" >>$CONFIGecho "#define 1ドル 0x${2##*[x,X]}" >>$CONFIG_H}function define_int () {eval 1ドル=\"2ドル\"echo "1ドル=2ドル" >>$CONFIGecho "#define 1ドル (2ドル)" >>$CONFIG_H}function define_string () {eval 1ドル=\"2ドル\"echo "1ドル=\"2ドル\"" >>$CONFIGecho "#define 1ドル\"2ドル\"" >>$CONFIG_H}function define_mystring () {eval 1ドル=2ドルecho "1ドル=2ドル" >>$CONFIGecho "#define 1ドル2ドル" >>$CONFIG_H}function define_mystring_null () {eval 1ドル=2ドル}function define_bool () {define_tristate "1ドル" "2ドル"}function define_tristate () {eval 1ドル=\"2ドル\"case "2ドル" iny)echo "1ドル=y" >>$CONFIGecho "#define 1ドル 1" >>$CONFIG_H;;m)if [ "$CONFIG_MODULES" = "y" ]thenecho "1ドル=m" >>$CONFIGecho "#undef 1ドル" >>$CONFIG_Hecho "#define 1ドル_MODULE 1" >>$CONFIG_Helseecho "1ドル=y" >>$CONFIGecho "#define 1ドル 1" >>$CONFIG_Hfi;;n)echo "1ドル=n" >>$CONFIGecho "#undef 1ドル" >>$CONFIG_H;;esac}function choice () {## Find the first choice that's already set to 'y'#choices="2ドル"default="3ドル"current=chosen=set -- $choiceswhile [ -n "2ドル" ]doif eval [ \"_\$2ドル\" = \"_y\" ]thencurrent=1ドルbreakfishift ; shiftdone## Use the default if none were set.#: ${current:=$default}## Output all choices (to be compatible with other configs).#set -- $choiceswhile [ -n "2ドル" ]docase "1ドル" in"$current"*) if [ -z "$chosen" ]; thendefine_bool "2ドル" "y"chosen=1elsedefine_bool "2ドル" "n"fi ;;*) define_bool "2ドル" "n" ;;esacshift ; shiftdone}function mainmenu_name () {:}function mainmenu_option () {comment_is_option=TRUE}function endmenu () {:}function comment () {if [ "$comment_is_option" ]thencomment_is_option=echo >>$CONFIGecho "#" >>$CONFIGecho "# 1ドル" >>$CONFIGecho "#" >>$CONFIGecho >>$CONFIG_Hecho "/*" >>$CONFIG_Hecho " * 1ドル" >>$CONFIG_Hecho " */" >>$CONFIG_Hfi}echo -n "."DEF_CONFIG="${1:-.config}"DEF_CONFIG_H="autoconf.h"CONFIG=.tmpconfigCONFIG_H=.tmpconfig.hecho "#" >$CONFIGecho "# Automatically generated by make menuconfig: don't edit" >>$CONFIGecho "#" >>$CONFIGecho "/*" >$CONFIG_Hecho " * Automatically generated by make menuconfig: don't edit" >>$CONFIG_Hecho " */" >>$CONFIG_Hecho "#define AUTOCONF_INCLUDED" >> $CONFIG_Hecho -n "."if . $CONFIG_IN >>.menuconfig.log 2>&1thenif [ -f "$DEF_CONFIG" ]thenrm -f ${DEF_CONFIG}.oldmv $DEF_CONFIG ${DEF_CONFIG}.oldfimv $CONFIG $DEF_CONFIGreturn 0elsereturn 1fi}## Remove temporary files#cleanup () {cleanup1cleanup2}cleanup1 () {rm -f MCmenu* MCradiolists MCdialog.out help.out}cleanup2 () {rm -f .tmpconfig .tmpconfig.h}set_geometry () {# Some distributions export these with incorrect values# which can really screw up some ncurses programs.LINES= COLUMNS=ROWS=${1:-24} COLS=${2:-80}# Just in case the nasty rlogin bug returns.#[ $ROWS = 0 ] && ROWS=24[ $COLS = 0 ] && COLS=80if [ $ROWS -lt 19 -o $COLS -lt 80 ]thenecho -e "\n0円07Your display is too small to run Menuconfig!"echo "It must be at least 19 lines by 80 columns."exit 1fiROWS=$((ROWS-4)) COLS=$((COLS-5))}set_geometry `stty size 2>/dev/null`menu_instructions="\Arrow keys navigate the menu. \<Enter> selects submenus --->. \Highlighted letters are hotkeys. \Pressing <Y> includes, <N> excludes. \Press <Esc><Esc> to exit, <?> for Help. \Legend: [*] included [ ] excluded"radiolist_instructions="\Use the arrow keys to navigate this window or \press the hotkey of the item you wish to select \followed by the <SPACE BAR>.Press <?> for additional information about this option."inputbox_instructions_int="\Please enter a decimal value. \Fractions will not be accepted. \Use the <TAB> key to move from the input field to the buttons below it."inputbox_instructions_hex="\Please enter a hexadecimal value. \Use the <TAB> key to move from the input field to the buttons below it."inputbox_instructions_string="\Please enter a string value. \Use the <TAB> key to move from the input field to the buttons below it."DIALOG="./scripts/lxdialog/lxdialog"minigui_version="${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}${EXTRAVERSION}"backtitle="MiniGUI v$minigui_version Configuration"trap "cleanup ; exit 1" 1 2 15## Locate default files.#CONFIG_IN=./config.inif [ "1ドル" != "" ] ; thenCONFIG_IN=1ドルfiDEFAULTS=configs/defconfigif [ -f .config ]; thenDEFAULTS=.configfiif [ -f .defconfig ]; thenDEFAULTS=.defconfigfiif [ -f $DEFAULTS ]thenecho "Using defaults found in" $DEFAULTSload_config_file $DEFAULTSelseecho "No defaults found"fi# Fresh new log.>.menuconfig.log# Load the functions used by the config.in files.echo -n "Preparing scripts: functions"load_functionsif [ ! -e $CONFIG_IN ]thenecho "Your main config.in file ($CONFIG_IN) does not exist"exit 1fiif [ ! -x $DIALOG ]thenecho "Your lxdialog utility does not exist"exit 1fi## Read config.in files and parse them into one shell function per menu.#echo -n ", parsing"parse_config_files $CONFIG_INecho "done."## Start the ball rolling from the top.#activate_menu MCmenu0## All done!#cleanup1## Confirm and Save#if $DIALOG --backtitle "$backtitle" \--yesno "Do you wish to save your new MiniGUI configuration?" 5 60thensave_configurationscripts/mkconfig./config-mnu#rm config-mnuechoechoecho "*** End of MiniGUI configuration."echo "*** Next, you must run 'make'."echoelseechoechoecho Your MiniGUI configuration changes were NOT saved.echofi# Remove log if empty.if [ ! -s .menuconfig.log ] ; thenrm -f .menuconfig.logfiexit 0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。