FORUMS

[KERNEL]How to build a custom Android Kernel for your device

1,205 posts
Thanks Meter: 2,825
 
By AmalD, Senior Member on 12th April 2012, 12:34 AM
Post Reply Email Thread
here is the guide

http://forum.xda-developers.com/show...81&postcount=4


thakz irfanbagus for the guide
The Following 22 Users Say Thank You to AmalD For This Useful Post: [ View ] Gift AmalD Ad-Free
12th April 2012, 02:51 AM |#2  
kurotsugi's Avatar
Senior Member
Flag yogyakarta
Thanks Meter: 1,816
 
More
where's the package link?have you try this guide by yourself?
12th April 2012, 03:23 AM |#3  
chenilen's Avatar
Member
Thanks Meter: 13
 
Donate to Me
More
i hope he tried
got a ubuntu, i will try this one (cross-fingers)
12th April 2012, 05:27 AM |#4  
Senior Member
Thanks Meter: 506
 
More
it's not working. sgy stock kernel do not have /proc/config.gz and gcc version in arm-2011.03 not compatible with other precompiled module.

this is work for me

requirement :
1. linux box 32 bit with working gcc. you can use real linux machine or virtual machine
2. Sourcery G++ Lite 2009q3-68 toolchain for ARM EABI from http://www.codesourcery.com/ (Linux version without installer arm-2009q3-68-arm-none-eabi-i686-pc-linux-gnu.tar.bz2)
3. mkbootimg with md5support. got it from http://forum.xda-developers.com/show...&postcount=241 . credit to harish2704
4. split_bootimg.pl (google it)
5. kernel source from http://opensource.samsung.com . i use GT-S5360_GB_Opensource_Update2.zip
6. stock boot.img (or from your custom kernel).

step :
1. make folder "sgy" in your home. the result is folder "/home/<yourname>/sgy". <yourname> is your linux user name, and from now replace <yourname> with your user name. put all file you already download there
2. extract "GT-S5360_Kernel.tar.gz" from "GT-S5360_GB_Opensource_Update2.zip". put also in "sgy" folder
3. open terminal emulator and go to your working path with command

Code:
cd ~/sgy
4. extract your compiler with

Code:
tar -xvf arm-2009q3-68-arm-none-eabi-i686-pc-linux-gnu.tar.bz2
5. create folder "kernel" and extract kernel source there

Code:
mkdir kernel
cd kernel
tar -xvf ../GT-S5360_Kernel.tar.gz
you got 2 folder, "common" and "modules"

6. open folder "common", there is file "Makefile". open with text editor and find line with content "/opt/toolchains/arm-eabi-4.4.3/bin/arm-eabi-". replace with "/home/<yourname>/sgy/arm-2009q3/bin/arm-none-eabi-", don't forget replace <yourname>.

7. in terminal goto folder "common" and load default config for sgy

Code:
cd ~/sgy/kernel/common
make bcm21553_totoro_05_defconfig
8. if you want change you config run

Code:
make menuconfig
9. if you ready to build then run

Code:
make
or if you have dual core cpu and want to make it faster

Code:
make -j3
10. when complete and no error appear, copy your kernel to "sgy" folder

Code:
cp arch/arm/boot/zImage ~/sgy
11. extract ramdisk from your boot.img

Code:
cd ~/sgy/
perl split_bootimg.pl boot.img
you got "boot.img-kernel" and "boot.img-ramdisk.gz". move "boot.img" and "boot.img-kernel" to other place.

12. repack your new kernel and ramdisk. but first get md5sum of your new kernel

Code:
md5sum zImage
you got something like

Code:
1fd319aa60abc2abae2e5932bcb9fc77  zImage
you need that "1fd319aa60abc2abae2e5932bcb9fc77" write it or copy to text editor. you need run it every time compile new kernel

13. repack

Code:
chmod +x mkbootimg
./mkbootimg --kernel zImage --ramdisk boot.img-ramdisk.gz --base 0x81600000 --kernelMD5 <your md5sum result> -o boot.img
14. make odin flash-able

Code:
tar -cf boot-sgy.tar boot.img
The Following 75 Users Say Thank You to irfanbagus For This Useful Post: [ View ] Gift irfanbagus Ad-Free
12th April 2012, 08:09 AM |#5  
kurotsugi's Avatar
Senior Member
Flag yogyakarta
Thanks Meter: 1,816
 
More
I thought you have to put your post into a new thread irfan...this one is a fake guide.
12th April 2012, 08:20 AM |#6  
Senior Member
Imphal
Thanks Meter: 105
 
More
Quote:
Originally Posted by kurotsugi

I thought you have to put your post into a new thread irfan...this one is a fake guide.

Irfan must create a guide.yes yes..I also think Irfan sahab must compile a CM7.2 from sources.
12th April 2012, 08:30 AM |#7  
kurotsugi's Avatar
Senior Member
Flag yogyakarta
Thanks Meter: 1,816
 
More
offtopic:
btw, do you know who's working on cm7 from source with motafoca?his thread is missing and I just get curious on their progress.
12th April 2012, 08:37 AM |#8  
Senior Member
Imphal
Thanks Meter: 105
 
More
Quote:
Originally Posted by kurotsugi

offtopic:
btw, do you know who's working on cm7 from source with motafoca?his thread is missing and I just get curious on their progress.

His thread was closed by moderator.You can request MOD to reopen his thread.Motafoca wanted a galacy y to be lended for his experiments

---------- Post added at 03:37 PM ---------- Previous post was at 03:33 PM ----------

Can someone download the sources around 15Gigs and stripe down the file and share it to Maroc ?
12th April 2012, 08:41 AM |#9  
Senior Member
Flag Pasay
Thanks Meter: 67
 
More
Whre can i download it?

Sent from my GT-S5360 using xda premium
12th April 2012, 09:33 AM |#10  
Senior Member
Thanks Meter: 506
 
More
Quote:
Originally Posted by kurotsugi

I thought you have to put your post into a new thread irfan...this one is a fake guide.

i don't call it fake. it's just too general and missing some detail (but critical) for our device. and in the 'spirit of operation iron fist', i think it's better to put here

Quote:
Originally Posted by premolikeshtc

Irfan must create a guide.yes yes..I also think Irfan sahab must compile a CM7.2 from sources.

with my internet connection, it will take weeks just to download the source. and i think cm, like android source, use repo. so you can't just download it. you clone it from their source repository, that mean no download accelerator.

btw beside kernel source, samsung also release their mod to android source. but to build it, you still need to get android source (about 10GB according their website).
The Following User Says Thank You to irfanbagus For This Useful Post: [ View ] Gift irfanbagus Ad-Free
12th April 2012, 10:11 AM |#11  
kurotsugi's Avatar
Senior Member
Flag yogyakarta
Thanks Meter: 1,816
 
More
well...thats your choice, irfan.

@sgy.creed: sorry, I don't mean to offend you. IMHO it will be nice if before someone post any guide they already have tested it by them. in this way, they'll able to give more accurate direction to anyone who need their guide. as we already know, kernel is crucial part in our device. any mistake in compiling it will lead to brick our device. we have to cautious on it. peace ^,^v
Post Reply Subscribe to Thread

Tags
sgy kernel

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes