The most important Busybox configurators are:
-
make defconfig - Create the maximum "sane" configuration. This enables almost all features, minus things like debugging options and features that require changes to the rest of the system to work (such as selinux or devfs device names). Use this if you want to start from a full-featured Busybox and remove features until it's small enough.
-
make allnoconfig - Disable everything. This creates a tiny version of Busybox that doesn't do anything. Start here if you know exactly what you want and would like to select only those features.
-
make menuconfig - Interactively modify a .config file through a multi-level menu interface. Use this after one of the previous two.
Some other configuration options are:
-
make oldconfig - Update an old .config file for a newer version of Busybox.
-
make allyesconfig - Select absolutely everything. This creates a statically linked version of Busybox full of debug code, with dependencies on selinux, using devfs names... This makes sure everything compiles. Whether or not the result would do anything useful is an open question.
-
make randconfig - Create a random configuration for test purposes.
make 目标 | 说明 |
---|---|
help | 显示 make 选项的完整列表 |
defconfig | 启用默认的(通用)配置 |
allnoconfig | 禁用所有的应用程序(空配置) |
allyesconfig | 启用所有的应用程序(完整配置) |
allbareconfig | 启用所有的应用程序,但是不包括子特性 |
config | 基于文本的配置工具 |
menuconfig | N-curses(基于菜单的)配置工具 |
all | 编译 BusyBox 二进制文件和文档(./docs) |
busybox | 编译 BusyBox 二进制文件 |
clean | 清除源代码树 |
distclean | 彻底清除源代码树 |
sizes | 显示所启用的应用程序的文本/数据大小 |
make oldconfig
通过命令界面配置内核,但是会自动载入既有的.config配置文件,并且只有在遇到先前没有设定过的选项时,才会要求你手动设定。然而,make config却会要求你手动设定所有的选项,即使你之前曾设定过。开发者通常会通过此方法将他们的配置更新为官方配置选项所做的变更,以避免重新设定整个内核的配置。