ubuntu 16.04 x86系统编译,raspberrypi 3 B的android内核过程

1、安装交叉编译器arm-linux-gnueabihf-xxx,

命令:apt-cache search arm-linux-gnueabihf ,搜索后得到如下结果,安装第一个软件包,命令为:

sudo apt install binutils-arm-linux-gnueabihf 

binutils-arm-linux-gnueabihf - GNU binary utilities, for arm-linux-gnueabihf target
cpp-5-arm-linux-gnueabihf - GNU C preprocessor
cpp-arm-linux-gnueabihf - GNU C preprocessor (cpp) for the armhf architecture
g++-5-arm-linux-gnueabihf - GNU C++ compiler
g++-arm-linux-gnueabihf - GNU C++ compiler for the armhf architecture
gcc-5-arm-linux-gnueabihf - GNU C compiler
gcc-5-arm-linux-gnueabihf-base - GCC, the GNU Compiler Collection (base package)
gcc-arm-linux-gnueabihf - GNU C compiler for the armhf architecture
cpp-4.7-arm-linux-gnueabihf - GNU C preprocessor
cpp-4.8-arm-linux-gnueabihf - GNU C preprocessor
cpp-4.9-arm-linux-gnueabihf - GNU C preprocessor
g++-4.7-arm-linux-gnueabihf - GNU C++ compiler
g++-4.7-multilib-arm-linux-gnueabihf - GNU C++ compiler (multilib files)
g++-4.8-arm-linux-gnueabihf - GNU C++ compiler
g++-4.8-multilib-arm-linux-gnueabihf - GNU C++ compiler (multilib support)
g++-4.9-arm-linux-gnueabihf - GNU C++ compiler
g++-4.9-multilib-arm-linux-gnueabihf - GNU C++ compiler (multilib support)
g++-5-multilib-arm-linux-gnueabihf - GNU C++ compiler (multilib support)
g++-multilib-arm-linux-gnueabihf - GNU C++ compiler for the armhf architecture
gcc-4.7-arm-linux-gnueabihf - GNU C compiler
gcc-4.7-arm-linux-gnueabihf-base - GCC, the GNU Compiler Collection (base package)
gcc-4.7-multilib-arm-linux-gnueabihf - GNU C compiler (multilib files)
gcc-4.8-arm-linux-gnueabihf - GNU C compiler
gcc-4.8-arm-linux-gnueabihf-base - GCC, the GNU Compiler Collection (base package)
gcc-4.8-multilib-arm-linux-gnueabihf - GNU C compiler (multilib support)
gcc-4.9-arm-linux-gnueabihf - GNU C compiler
gcc-4.9-arm-linux-gnueabihf-base - GCC, the GNU Compiler Collection (base package)
gcc-4.9-multilib-arm-linux-gnueabihf - GNU C compiler (multilib support)
gcc-5-multilib-arm-linux-gnueabihf - GNU C compiler (multilib support)
gcc-multilib-arm-linux-gnueabihf - GNU C compiler for the armhf architecture
gccgo-4.7-arm-linux-gnueabihf - GNU Go compiler
gccgo-4.8-arm-linux-gnueabihf - GNU Go compiler
gccgo-4.9-arm-linux-gnueabihf - GNU Go compiler
gccgo-5-arm-linux-gnueabihf - GNU Go compiler
gccgo-arm-linux-gnueabihf - Go compiler (based on GCC) for the armhf architecture
gcj-4.8-arm-linux-gnueabihf - GCJ byte code and native compiler for Java(TM)
gcj-4.9-arm-linux-gnueabihf - GCJ byte code and native compiler for Java(TM)
gcj-5-arm-linux-gnueabihf - GCJ byte code and native compiler for Java(TM)
gcj-arm-linux-gnueabihf - GNU Java compiler (based on GCC) for the armhf architecture
gdc-4.8-arm-linux-gnueabihf - GNU D compiler (version 2), based on the GCC backend
gdc-4.9-arm-linux-gnueabihf - GNU D compiler (version 2), based on the GCC backend
gdc-5-arm-linux-gnueabihf - GNU D compiler (version 2)
gdc-5-multilib-arm-linux-gnueabihf - GNU D compiler (version 2, multilib support)
gdc-arm-linux-gnueabihf - GNU D compiler (based on GCC) for the armhf architecture
gdc-multilib-arm-linux-gnueabihf - GNU D compiler (based on GCC) for the armhf architecture
gfortran-4.7-arm-linux-gnueabihf - GNU Fortran compiler
gfortran-4.7-multilib-arm-linux-gnueabihf - GNU Fortran compiler (multilib files)
gfortran-4.8-arm-linux-gnueabihf - GNU Fortran compiler
gfortran-4.8-multilib-arm-linux-gnueabihf - GNU Fortran compiler (multilib support)
gfortran-4.9-arm-linux-gnueabihf - GNU Fortran compiler
gfortran-4.9-multilib-arm-linux-gnueabihf - GNU Fortran compiler (multilib support)
gfortran-5-arm-linux-gnueabihf - GNU Fortran compiler
gfortran-5-multilib-arm-linux-gnueabihf - GNU Fortran compiler (multilib support)
gfortran-arm-linux-gnueabihf - GNU Fortran 95 compiler for the armhf architecture
gfortran-multilib-arm-linux-gnueabihf - GNU Fortran 95 compiler for the armhf architecture
gnat-5-arm-linux-gnueabihf - GNU Ada compiler
gnat-5-sjlj-arm-linux-gnueabihf - GNU Ada compiler (setjump/longjump runtime library)
gobjc++-4.7-arm-linux-gnueabihf - GNU Objective-C++ compiler
gobjc++-4.7-multilib-arm-linux-gnueabihf - GNU Objective-C++ compiler (multilib files)
gobjc++-4.8-arm-linux-gnueabihf - GNU Objective-C++ compiler
gobjc++-4.8-multilib-arm-linux-gnueabihf - GNU Objective-C++ compiler (multilib support)
gobjc++-4.9-arm-linux-gnueabihf - GNU Objective-C++ compiler
gobjc++-4.9-multilib-arm-linux-gnueabihf - GNU Objective-C++ compiler (multilib support)
gobjc++-5-arm-linux-gnueabihf - GNU Objective-C++ compiler
gobjc++-5-multilib-arm-linux-gnueabihf - GNU Objective-C++ compiler (multilib support)
gobjc++-arm-linux-gnueabihf - GNU Objective-C++ compiler for the armhf architecture
gobjc++-multilib-arm-linux-gnueabihf - GNU Objective-C++ compiler for the armhf architecture
gobjc-4.7-arm-linux-gnueabihf - GNU Objective-C compiler
gobjc-4.7-multilib-arm-linux-gnueabihf - GNU Objective-C compiler (multilib files)
gobjc-4.8-arm-linux-gnueabihf - GNU Objective-C compiler
gobjc-4.8-multilib-arm-linux-gnueabihf - GNU Objective-C compiler (multilib support)
gobjc-4.9-arm-linux-gnueabihf - GNU Objective-C compiler
gobjc-4.9-multilib-arm-linux-gnueabihf - GNU Objective-C compiler (multilib support)
gobjc-5-arm-linux-gnueabihf - GNU Objective-C compiler
gobjc-5-multilib-arm-linux-gnueabihf - GNU Objective-C compiler (multilib support)
gobjc-arm-linux-gnueabihf - GNU Objective-C compiler for the armhf architecture
gobjc-multilib-arm-linux-gnueabihf - GNU Objective-C compiler for the armhf architecture
pkg-config-arm-linux-gnueabihf - manage compile and link flags for libraries for armhf architecture
qt5-qmake-arm-linux-gnueabihf - Qt 5 qt5-qmake-arm-linux-gnueabihf Makefile generator tool
gcc-5-plugin-dev-arm-linux-gnueabihf - Files for GNU GCC plugin development.

2、从github下载rpi3的内核代码

git clone https://github.com/android-rpi/kernel_rpi.git

3、进入内核源码目录

cd kernel_rpi

4、生成config文件

ARCH=arm scripts/kconfig/merge_config.sh arch/arm/configs/bcm2709_defconfig android/configs/android-base.cfg android/configs/android-recommended.cfg
5、编译生成内核zImage

ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make -j8 zImage

6、编译生成dtb

ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make dtbs

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值