QNA > H > How To Learn To Develop A Custom Android Kernel

How to learn to develop a custom Android kernel

If you havn’t used linux before, learn some basics first.

If you are already a linux user, here you go :

Grab your Sources from your device manufacturer or search it on xda, someone already have done some work for you.

Extract the source.

Use

  1. unzip kernel_source_filename.zip 

Now go to arch/arm/configs directory if your phone is a arm one, or go to arch/arm64/configs/, you will find a lot of files there, find the one with name like your_device_codename_defconfig

Copy that name.

Download gcc toolchain from google sources

Not all versions will work with every kernel source, so keep that in mind.

Extract the toolchain in any folder

Go to the root directory of your kernel sources,

Type :

  1. export CROSS_COMPILE=/your/toolchain/location/here/bin/arm-eabi- 
  2. export ARCH=arm 
  3. or  
  4. export ARCH=arm64 
  5. make your_device_codename_here_defconfig 
  6. make zImage 

Go & get a cup of coffee.

Your kernel will be ready in few minutes in arch/arm/boot directory.

If you didn’t understand all of the above, watch this video :)

Di Hortensa Douse

Cosa si intende per versione del kernel? :: Cosa si intende per versione del kernel in un telefono cellulare?
Link utili