1. Package-to-install in Ubuntu or Debian
$ sudo apt-get install-y build-essential kernel-package libncurses5-dev bzip2
2. Prepare Kernel Source and excute the command
$ make clean && make Mrproper
3. Excute the command:the default Config file location/arch/arm/configs/yourdevice_defconfig
$ make Yourdevice_defconfig
- Or If you have the Android SDK installed you can get your config by executing the following:
$ adb pull/proc/config.gz
$ gunzip config.gz
4. Point the ' Makefile ' to the compilation tools
$ Export cross_compile=/home/***/ndk/toolchains/arm-eabi-4.4.0/prebuilt/linux-x86/bin/arm-eabi-
5, Apply any kernel patches ie. BFS, BFQ etc.
$ PATCH-P1 < Yourpatch.patch
6. Further configure your kernel if so desired:
$ make Menuconfig
7. Execute Compile command:
$ make-j5 Arch=arm
8. Kernel & Wifi Module locations after compilation:
/arch/arm/boot/zimage
/drivers/net/wireless/bcm4329_204/bcm4329.ko
Build a Custom Android Kernel guide