Linux下配置交叉编译环境,配置编译内核及uboot安装
2006-01-05 11:55
861 查看
本文是在H9200E开发板上实验,linux为fedora 3.首先将cross-2.95.3.tar.bz2(交叉编译器),linux-2.4.19-rmk7.tar.gz,kernel-h9200-050718.tgz还有u-boot-1.0.0.tar.gz复制到/root下.
一.安装交叉编译器
以超级用户身份登录
[root@hostname]# bunzip2 cross-2.95.3.tar.bz2 ;解压
[root@hostname]# tar xvf cross-2.95.3.tar
然后将得到的2.95.3文件夹放到/usr/local/arm下,注意记住这个路径后面要用到.
二.配置内核
以H9200E的最小配置为例
三.编译内核
解压内核源码包,编辑Makefile
设置 cross_compile:=[编译器的绝对路径] ;这个绝对路径既上面2.95.3放到的路径
进入内核文件夹,执行下面命令
[root@hostname]# make clean
[root@hostname]# make dep
[root@hostname]# make
[root@hostname]# [编译器的绝对路径]/bin/arm-linux-objcopy -O binary -S vmlinux linux.bin ;编译器的绝对路径也是上面说到的路径
[root@hostname]# gzip linux.bin
下面的比较重要了,主要是u-boot的安装,这个在H9200的手册上说的很不清楚
[root@hostname]# tar xzvf u-boot-1.0.0.tar.gz ;解压u-boot
[root@hostname]# cd u-boot-1.0.0
[root@hostname]# make distclean
[root@hostname]# make at91rm9200dk_config
[root@hostname]# make all
然后在/usr/local下建立uboot文件夹将u-boot-1.0.0下的所有文件都复制到uboot下
[root@hostname]# [uboot的绝对路径]/tools/mkimage -A arm -O linux -C gzip -a 0x20008000 -e 0x20008000 -d linux.bin.gz uImage ;这里的绝对路径是/usr/local/uboot
好了,内核编译好了,可以下到板子里看看了!!!
一.安装交叉编译器
以超级用户身份登录
[root@hostname]# bunzip2 cross-2.95.3.tar.bz2 ;解压
[root@hostname]# tar xvf cross-2.95.3.tar
然后将得到的2.95.3文件夹放到/usr/local/arm下,注意记住这个路径后面要用到.
二.配置内核
以H9200E的最小配置为例
三.编译内核
解压内核源码包,编辑Makefile
设置 cross_compile:=[编译器的绝对路径] ;这个绝对路径既上面2.95.3放到的路径
进入内核文件夹,执行下面命令
[root@hostname]# make clean
[root@hostname]# make dep
[root@hostname]# make
[root@hostname]# [编译器的绝对路径]/bin/arm-linux-objcopy -O binary -S vmlinux linux.bin ;编译器的绝对路径也是上面说到的路径
[root@hostname]# gzip linux.bin
下面的比较重要了,主要是u-boot的安装,这个在H9200的手册上说的很不清楚
[root@hostname]# tar xzvf u-boot-1.0.0.tar.gz ;解压u-boot
[root@hostname]# cd u-boot-1.0.0
[root@hostname]# make distclean
[root@hostname]# make at91rm9200dk_config
[root@hostname]# make all
然后在/usr/local下建立uboot文件夹将u-boot-1.0.0下的所有文件都复制到uboot下
[root@hostname]# [uboot的绝对路径]/tools/mkimage -A arm -O linux -C gzip -a 0x20008000 -e 0x20008000 -d linux.bin.gz uImage ;这里的绝对路径是/usr/local/uboot
好了,内核编译好了,可以下到板子里看看了!!!
相关文章推荐
- 【课程分享】深入浅出嵌入式linux系统移植开发 (环境搭建、uboot的移植、嵌入式内核的配置与编译)
- Ubuntu配置安装ARM Linux交叉编译环境完整流程
- 交叉编译环境的搭建(Linux-2.6.32内核)
- Linux + Eclipse 配置交叉编译环境
- ubuntu12.04 (32/64 bits) 安装配置 arm-linux-gcc-4.5.1 交叉编译工具链
- Linux 下的 FFmpeg 安装编译环境配置总结
- 安装交叉编译工具arm-linux-gcc-4.3.2 并且修改环境变量
- Linux 交叉编译环境详细配置
- linux下LAMP环境配置之apache-2.4.27编译安装
- Windows下Linux开发环境设置--安装Cygwin及交叉编译工具链
- Linux + Eclipse 配置交叉编译环境
- 安装交叉编译环境arm-linux-gcc
- arm-linux-gcc交叉编译环境安装
- Linux环境下apache阿帕奇安装配置失败报错,编译失败的解决方案,Apache安装升级OpsenSSL步骤
- ubuntu14.0安装arm-linux-gcc交叉编译环境
- Linux下配置交叉编译环境arm-none-eabi-gcc
- Linux + ARM驱动开发环境配置(内核配置与编译)
- Linux + Eclipse 配置交叉编译环境
- Linux 交叉编译环境详细配置
- linux下LAMP环境配置之apache-2.4.27编译安装