busybox-1.31.1配置与编译

1.修改ARCH、CROSS_COMPILE

2.make defconfig

3.make menuconfig

Settings--->
	Build Options--->
		[*]Build static binary (no shared libs)		
	Library Tuning--->
		[*]vi-style line editing commands
		[*]Fancy shell prompts
	
	
Linux Module Utilities--->
	[ ]Simplified modutils
	[*]insmod
	[*]rmmod
	[*]lsmod
	[*]modprobe
	[*]depmod


(默认是选中的)	
Linux System Utilities--->
	[*]mdev
		[*]Support /etc/mdev.conf
		[*]Support subdirs/symlinks
		[*]Support regular expressions substitutions when renaming dev
		[*]Support command execution at device addition/removal
		[*]Support loading of firmwares
	[ ]nsenter


Coreutils--->
	[ ]sync

4.make
报错:
networking/libiproute/ipaddress.c: In function ‘print_addrinfo’:
networking/libiproute/ipaddress.c:333: error: ‘IFA_F_DADFAILED’ undeclared (first use in this function)
networking/libiproute/ipaddress.c:333: error: (Each undeclared identifier is reported only once
networking/libiproute/ipaddress.c:333: error: for each function it appears in.)
make[1]: *** [networking/libiproute/ipaddress.o] Error 1
make: *** [networking/libiproute] Error 2

修改
networking/libiproute/ipaddress.c:333:
添加条件编译
#ifdef IFA_F_DADFAILED 	//添加
		if (ifa->ifa_flags & IFA_F_DADFAILED) {
				ifa->ifa_flags &= ~IFA_F_DADFAILED;
				printf("dadfailed ");
		}
#endif			//添加

5.重新make

6.make install

7.制作ext2根文件系统rootfs
参考:http://blog.csdn.net/zhengmeifu/article/details/24174513

你可能感兴趣的:(busybox-1.31.1配置与编译)