看U-boot的make文件,在帮助页面发现一片config方法,逐一尝试,看看有什么区别
注意,下面使用的make命令中都带有 O=/tmp/build 表示所有的输出文件都放到/tmp/build目录中,而这个目录是临时目录,关机时将被清空,如果不需要可以删去或者更换目录
Configuration targets:
config - Update current config utilising a line-oriented program
nconfig - Update current config utilising a ncurses menu based program
menuconfig - Update current config utilising a menu based program
xconfig - Update current config utilising a Qt based front-end
gconfig - Update current config utilising a GTK+ based front-end
oldconfig - Update current config utilising a provided .config as base
localmodconfig - Update current config disabling modules not loaded
localyesconfig - Update current config converting local mods to core
defconfig - New config with default from ARCH supplied defconfig
savedefconfig - Save current config as ./defconfig (minimal config)
allnoconfig - New config where all options are answered with no
allyesconfig - New config where all options are accepted with yes
allmodconfig - New config selecting modules when possible
alldefconfig - New config with all symbols set to default
randconfig - New config with random answer to all options
listnewconfig - List new options
olddefconfig - Same as oldconfig but sets new symbols to their default value without prompting
config
使用命令
make O=/tmp/build config
效果如下图
终端会列出所有配置项,需要依次选择,上百甚至几百个配置项选择非常耗时,不建议使用。
nconfig
使用命令
make O=/tmp/build nconfig
效果如下图
比单纯的config界面要友好些,使用方向键操作。好像不需要什么特殊的支持库,我电脑上是直接使用的。
menuconfig
使用最多的一种配置方法
可能提示缺的支持库
sudo apt-get install libncurses5-dev
使用命令
make O=/tmp/build menuconfig
效果如下图
越来越好看了,虽然还是文本的,但是多了一些背景,看起来像是视窗的。
xconfig
带QT界面的配置软件
需要先安装qt库
sudo apt-get install libqt4-dev
后使用
make O=/tmp/build xconfig
效果如下图
使用鼠标点一点就可以配置好,和windows环境非常类似。
gconfig
带GTK+界面的配置软件
需要先安装GTK+库
sudo apt-get install gtk+-2.0 glib-2.0 libglade2-dev
后使用
make O=/tmp/build gconfig
效果如下图