2. Ubuntu download compiled Linux kernel

Source: Internet
Author: User

I. INTRODUCTION

As Loro says, there is no Linux kernel code in the Android source code. It uses pre-compiled kernel, which you can see using the ADB shell cat Proc/version, as follows:

[Email protected]:~/working_directory$ adb shell Cat proc/version

Linux version 2.6.29-00261-g0097074-dirty ([email protected]) (GCC version 4.4.0 (gcc)) #20 Wed Mar 09:54:02 PDT 2010

[Email protected]:~/working_directory$


From the kernel version you can see the current use or Google in the 2010 compiled kernel, how to download/compile/run their own kernel it?


Two. Download kernel

Please refer to Lao Luo's blog for download methods.

http://blog.csdn.net/luoshengyang/article/details/6564592

But there is a place to note, similar to the 1th post, because the address is the wall, can not download the success (at least I did not succeed ...)

So we have to go to the mirror station of Tsinghua University to download


Https://aosp.tuna.tsinghua.edu.cn/kernel/goldfish.git

1. Create a new kernel directory

mkdir kernel

CD kernel


2. Git clone https://aosp.tuna.tsinghua.edu.cn/kernel/goldfish.git


Enter the Goldfish directory when clone is complete

3. CD Goldfish


4. Git branch-a View Remote branch

[Email protected]:~/working_directory/kernel/goldfish$ git branch-a

* Master

Remotes/origin/head-Origin/master

remotes/origin/android-3.10

remotes/origin/android-3.18

remotes/origin/android-3.4

remotes/origin/android-goldfish-2.6.29

remotes/origin/android-goldfish-3.10

Remotes/origin/android-goldfish-3.10-l-mr1-dev

Remotes/origin/android-goldfish-3.10-m-dev

Remotes/origin/android-goldfish-3.18-dev

remotes/origin/android-goldfish-3.4

Remotes/origin/android-goldfish-3.4-l-mr1-dev

Remotes/origin/linux-goldfish-3.0-wip

Remotes/origin/master

[Email protected]:~/kerle_test/goldfish$


5. Switch to the Android-goldfish-2.6.29 branch, as this branch and the 2.3 version are the closest.

git checkout-b android-goldfish-2.6.29 origin/android-goldfish-2.6.29


6. View local branch and remote branch correspondence

Git branch-avv


650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M00/7A/F5/wKioL1bDCZKB-4_8AAKnwI16F7U558.png "title=" View git remote repository 2.png "alt=" Wkiol1bdczkb-4_8aaknwi16f7u558.png "/>



You can see our local android-goldfish-2.6.29 Branch and Remote branch "4bb8fa0 [origin/android-goldfish-2.6.29] goldfish:add encrypted SD Card Support. " is the corresponding.


At this point, the kernel code is finished downloading.


In addition, I found that the default download kernel folder is goldfish, do not know why Lao Luo is common, perhaps his git command to specify a folder bar.


Three. Compiling kernel

If you compile kernel, please refer to Lao Luo's method, configure the cross-compilation environment, compile with make command

http://blog.csdn.net/luoshengyang/article/details/6564592


Ps:

Make Menuconfig is the boot configuration menu, and you can configure compilation options.


Four. Run your own kernel

Emulator-kernel./kernel/common/arch/arm/boot/zimage


Lao Luo's order is emulator-kernel./kernel/common/arch/arm/boot/zimage &


But it's not possible to find this & to work.





This article is from the "www.bogo.com" blog, make sure to keep this source http://483181.blog.51cto.com/473181/1742559

2. Ubuntu download compiled Linux kernel

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.