Building and booting Nexus 5 kernel

Posted Jeremy 學習筆記

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Building and booting Nexus 5 kernel相关的知识,希望对你有一定的参考价值。

1. Downloading toolchain and setup.

git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7/

2. Downloading kernel source code :

$git clone https://android.googlesource.com/kernel/msm.git
looking into kernel version : 3.4.0-gd59db4e
$git checkout -b android-msm-hammerhead-3.4-kitkat-mr1 origin/android-msm-hammerhead-3.4-kitkat-mr1

switch to this branch; otherwise doesn't compile yet.
$make ARCH=arm SUBARCH=arm hammerhead_defconfig
$make -j16 ARCH=arm SUBARCH=arm CROSS_COMPILE=arm-eabi- 2>&1 |tee kernel_make.out
alias makenexus5="make -j16 ARCH=arm KCFLAGS=-ggdb3 CROSS_COMPILE=arm-eabi-"

```
OBJCOPY arch/arm/boot/zImage
Kernel: arch/arm/boot/zImage is ready
CAT     arch/arm/boot/zImage-dtb
Kernel: arch/arm/boot/zImage-dtb is ready
```

3. Repacking Android image:

https://github.com/xiaolu/mkbootimg_tools.git

4. Flashing the custom kernel

let's try and check if it works or not.
Connect your phone using USB cable to your PC, 
be sure that you have USB debugging enabled.

$ adb start-server
    * daemon not running. starting it now on port 5037 *
    * daemon started successfully *
$ adb reboot bootloader
$ fastboot flash boot boot.img

ref :

http://marcin.jabrzyk.eu/posts/2014/05/building-and-booting-nexus-5-kernel
http://pete.akeo.ie/2013/10/compiling-and-running-your-own-android.html

以上是关于Building and booting Nexus 5 kernel的主要内容,如果未能解决你的问题,请参考以下文章

Building Microservices with Spring Boot and Apache Thrift. Part 2. Swifty services

Collection Views and Building Custom Layouts-备

Building a Service Mesh with HAProxy and Consul

「机器视觉」学习笔记 - Constructing And Building Histograms

Building and using plug-ins for Android

ITK Configuring and Building in VisualStudio及hello world程序编译