Introduction
------------
The configuration database is a collection of configuration options
organized in a tree structure:
+- Code maturity level options
| +- Prompt for development and/or incomplete code/drivers
+- General setup
| +- Networking support
| +- System V IPC
| +- BSD Process Accounting
| +- Sysctl support
+- Loadable module support
| +- Enable loadable module support
| +- Set version information on all module symbols
| +- Kernel module loader
+- ...
Every entry has its own dependencies. These dependencies are used
to determine the visibility of an entry. Any child entry is only
visible if its parent entry is also visible.
Menu entries
------------
Most entries define a config option; all other entries help to organize
them. A single configuration option is defined like this:
config MODVERSIONS
bool "Set version information on all module symbols"
depends on MODULES
help
Usually, modules have to be recompiled whenever you switch to a new
kernel. ...
Every line starts with a key word and can be followed by multiple
arguments. "config" starts a new config entry. The following lines
define attributes for this config option. Attributes can be the type of
the config option, input prompt, dependencies, help text and default
values. A config option can be defined multiple times with the same
name, but every definition can have only a single input prompt and the
type must not conflict.
Menu attributes
---------------
A menu entry can have a number of attributes. Not all of them are
applicable everywhere (see syntax).
- type definition: "bool"/"tristate"/"string"/"hex"/"int"
Every config option must have a type. There are only two basic types:
tristate and string; the other types are based on these two. The type
definition optionally accepts an input prompt, so these two examples
are equivalent:
bool "Networking support"
and
bool
prompt "Networking support"
- input prompt: "prompt" <prompt> ["if" <expr>]
Every menu entry can have at most one prompt, which is used to display
to the user. Optionally dependencies only for this prompt can be added
with "if".
- default value: "default" <expr> ["if" <expr>]
A config option can have any number of default values. If multiple
default values are visible, only the first defined one is active.
Default values are not limited to the menu entry where they are
defined. This means the default can be defined somewhere else or be
overridden by an earlier definition.
The default value is only assigned to the config symbol if no other
value was set by the user (via the input prompt above). If an input
prompt is visible the default value is presented to the user and can
be overridden by him.
Optionally, dependencies only for this default value can be added with
"if".
- type definition + default value:
"def_bool"/"def_tristate" <expr> ["if" <expr>]
This is a shorthand notation for a type definition plus a value.
Optionally dependencies for this default value can be added with "if".
- dependencies: "depends on" <expr>
This defines a dependency for this menu entry. If multiple
dependencies are defined, they are connected with '&&'. Dependencies
are applied to all other options within this menu entry (which also
accept an "if" expression), so these two examples are equivalent:
bool "foo" if BAR
default y if BAR
and
depends on BAR
bool "foo"
default y
- reverse dependencies: "select" <symbol> ["if" <expr>]
While normal dependencies reduce the upper limit of a symbol (see
below), reverse dependencies can be used to force a lower limit of
another symbol. The value of the current menu symbol is used as the
minimal value <symbol> can be set to. If <symbol> is selected multiple
times, the limit is set to the largest selection.
Reverse dependencies can only be used with boolean or tristate
symbols.
Note:
select should be used with care. select will force
a symbol to a value without visiting the dependencies.
By abusing select you are able to select a symbol FOO even
if FOO depends on BAR that is not set.
In general use select only for non-visible symbols
(no prompts anywhere) and for symbols with no dependencies.
That will limit the usefulness but on the other hand avoid
the illegal configurations all over.
- limiting menu display: "visible if" <expr>
This attribute is only applicable to menu blocks, if the condition is
false, the menu block is not displayed to the user (the symbols
contained there can still be selected by other symbols, though). It is
similar to a conditional "prompt" attribute for individual menu
entries. Default value of "visible" is true.
- numerical ranges: "range" <symbol> <symbol> ["if" <expr>]
This allows to limit the range of possible input values for int
and hex symbols. The user can only input a value which is larger than
or equal to the first symbol and smaller than or equal to the second
symbol.
- help text: "help" or "---help---"
This defines a help text. The end of the help text is determined by
the indentation level, this means it ends at the first line which has
a smaller indentation than the first line of the help text.
"---help---" and "help" do not differ in behaviour, "---help---" is
used to help visually separate configuration logic from help within
the file as an aid to developers.
- misc options: "option" <symbol>[=<value>]
Various less common options can be defined via this option syntax,
which can modify the behaviour of the menu entry and its config
symbol. These options are currently possible:
- "defconfig_list"
This declares a list of default entries which can be used when
looking for the default configuration (which is used when the main
.config doesn't exists yet.)
- "modules"
This declares the symbol to be used as the MODULES symbol, which
enables the third modular state for all config symbols.
- "env"=<value>
This imports the environment variable into Kconfig. It behaves like
a default, except that the value comes from the environment, this
also means that the behaviour when mixing it with normal defaults is
undefined at this point. The symbol is currently not exported back
to the build environment (if this is desired, it can be done via
another symbol).
Menu dependencies
-----------------
Dependencies define the visibility of a menu entry and can also reduce
the input range of tristate symbols. The tristate logic used in the
expressions uses one more state than normal boolean logic to express the
module state. Dependency expressions have the following syntax:
<expr> ::= <symbol> (1)
<symbol> '=' <symbol> (2)
<symbol> '!=' <symbol> (3)
'(' <expr> ')' (4)
'!' <expr> (5)
<expr> '&&' <expr> (6)
<expr> '||' <expr> (7)
Expressions are listed in decreasing order of precedence.
(1) Convert the symbol into an expression. Boolean and tristate symbols
are simply converted into the respective expression values. All
other symbol types result in 'n'.
(2) If the values of both symbols are equal, it returns 'y',
otherwise 'n'.
(3) If the values of both symbols are equal, it returns 'n',
otherwise 'y'.
(4) Returns the value of the expression. Used to override precedence.
(5) Returns the result of (2-/expr/).
(6) Returns the result of min(/expr/, /expr/).
(7) Returns the result of max(/expr/, /expr/).
An expression can have a value of 'n', 'm' or 'y' (or 0, 1, 2
respectively for calculations). A menu entry becomes visible when its
expression evaluates to 'm' or 'y'.
There are two types of symbols: constant and non-constant symbols.
Non-constant symbols are the most common ones and are defined with the
'config' statement. Non-constant symbols
没有合适的资源?快使用搜索试试~ 我知道了~
uClibc-ng-1.0.42.tar.gz:openwrt系统中使用的精简版的glibc库
需积分: 7 0 下载量 89 浏览量
2023-02-28
13:50:53
上传
评论
收藏 3.27MB GZ 举报
温馨提示
共2000个文件
c:2103个
h:1505个
s:614个
uClibc-ng-1.0.42.tar.gz:openwrt系统中使用的精简版的glibc库。
资源推荐
资源详情
资源评论
收起资源包目录
uClibc-ng-1.0.42.tar.gz:openwrt系统中使用的精简版的glibc库 (2000个子文件)
resolv.c 124KB
regexec.c 123KB
regcomp.c 106KB
gen_collate.c 98KB
time.c 66KB
argp-help.c 59KB
_scanf.c 52KB
_vfprintf.c 48KB
wordexp.c 48KB
ldso.c 44KB
regex_internal.c 44KB
unifdef.c 43KB
locale.c 40KB
wchar.c 40KB
gconf.c 39KB
nconf.c 38KB
getconf.c 38KB
pthread.c 38KB
libdl.c 35KB
malloc.c 35KB
dl-elf.c 34KB
ctype.c 33KB
manager.c 33KB
getopt.c 32KB
allocatestack.c 32KB
dl-tls.c 31KB
argp-parse.c 30KB
gen_locale.c 30KB
fts.c 30KB
symbol.c 29KB
fnmatch_loop.c 29KB
mconf.c 28KB
expr.c 27KB
glob.c 26KB
confdata.c 26KB
getaddrinfo.c 26KB
dl-tls.c 25KB
stdlib.c 25KB
ldconfig.c 25KB
ifaddrs.c 23KB
gen_wctype.c 22KB
ldd.c 21KB
k_standard.c 21KB
spinlock.c 21KB
pwd_grp.c 21KB
_wctype.c 20KB
des.c 19KB
ftw.c 19KB
sysconf.c 19KB
md5.c 18KB
gen_wc8bit.c 18KB
util.c 18KB
old_vfprintf.c 18KB
_fpmaxtostr.c 17KB
conf.c 17KB
menu.c 17KB
pthread_create.c 16KB
msgfmt.c 16KB
__uClibc_main.c 16KB
_collate.c 16KB
_strtod.c 15KB
timer_routines.c 15KB
iconv.c 15KB
nconf.gui.c 15KB
dl-startup.c 14KB
e_j0.c 14KB
e_j1.c 14KB
e_sqrt.c 14KB
elfinterp.c 13KB
pthread_mutex_lock.c 13KB
pthread_mutex_timedlock.c 13KB
argp-fmtstream.c 13KB
elfinterp.c 13KB
fnmatch.c 13KB
_stdio.c 13KB
free.c 12KB
dl-hash.c 12KB
init.c 12KB
e_lgamma_r.c 11KB
elfinterp.c 11KB
socketcalls.c 11KB
rwlock.c 11KB
join.c 11KB
sem_open.c 11KB
random_r.c 11KB
menubox.c 11KB
mutex.c 11KB
s_erf.c 11KB
locale.c 11KB
sha512-crypt.c 11KB
stubs.c 11KB
elfinterp.c 10KB
sha512.c 10KB
condvar.c 10KB
random.c 10KB
syslog.c 10KB
pthread_mutex_trylock.c 10KB
sha256-crypt.c 10KB
gen_ldc.c 10KB
elfinterp.c 10KB
共 2000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 20
资源评论
李小白20200202
- 粉丝: 3561
- 资源: 70
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 四数之和(java代码).docx
- 701837906919458TapScanner v3.0.10 (Pro).apk
- 青岛大学人工智能实验二 利用α-β搜索的博弈树算法编写一字棋游戏
- ### 1、项目介绍 本项目Scrapy进行数据爬取,并使用Django框架+PyEcharts实现可视化大屏 效果如下:
- # 微信小程序-健康菜谱 基于微信小程序的一个查找检索菜谱的应用 ### 效果 !动态图(./res/gif/demo
- zabbix-get命令包资源
- 289ssm-mysql-jsp 计算机课程实验管理系统.zip(可运行源码+数据库文件+文档)
- 毕业设计,基于PyQt5实现的可视化界面的Python车牌自动识别系统源码
- 20-天天果园项目.rar
- 26-朴素贝叶斯分类.rar
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功