I created this topic in order to improve our spica ...
... I know that we haven't much real kernel-developer here but we have motivated people with some basic linux / C / C++ know-how and to make the first steps simpler I post this tutorial to explain the compilation of the kernel.
First step: install linux + cross compiler
you have to install Linux first (e.g. Ubuntu, Debian ...) but you can also install this as a virtual PC e.g. with VirtualBox. Now open a Terminal and install this software ->
PS: you can also try gcc-4.6 (info) if you add this to your repository (/etc/apt/sources.list) -> *only tested with debian sid*
sudo apt-get install build-essential git gcc-4.5-arm-linux-gnueabi wget libncurses5-dev
or you can build your own cross-compiler -> HowTo
deb http://www.emdebian.org/debian/ unstable main
2nd step: download the source
in this example I show you how to get my sources for Kernel 126.96.36.199. Open a Terminal again and type this ->
PS: "~" (tilde) the home directory (normally the directory /home/my_login_name). (info)
mkdir -p ~/spica/voku-kernel/
git clone https://github.com/voku/i5700-sm-kernel.git
mv i5700-sm-kernel/ kernel/
git clone https://github.com/voku/i5700-sm-froyo-initramfs.git
mv i5700-sm-froyo-initramfs/ initramfs/
git clone https://github.com/voku/i5700-sm-kmodules2.git
mv i5700-sm-kmodules2/ modules/
Step 4: change the config / your path to the files
Step 4.1: the "config"-file: .config
Every kernel version comes with a "default" kernel configuration. This configuration is loosely based on the defaults that the kernel maintainer of that architecture feels are the best options to be used. and you will find different config-files here (~/spica/voku-kernel/kernel/arch/arm/configs/...) for the first time you maybe can try my config file
if you try different directory-names for the initramfs you have to change ths path e.g.:
mv spica_config.txt .config
if you will change 16bpp to 24bpp change this
Step 4.2: the "Makefile":
A makefile specifies a set of compilation rules in terms of targets (such as executables) and their dependencies (such as object files and source files) e.g. if you try gcc 4.5 you have to change -Ofast to -O2 or -O3 in this file. Maybe you have also change the "CROSS_COMPILE"-variable with the path to your installed cross-compiler. (info & info)
Step 4.3: initrd.arm.initramfs_list
CROSS_COMPILE := /usr/bin/arm-linux-gnueabi-
You have also to change the path in this file e.g.:
Step 4.4: the "init.rc"-file
sed -i '/\/home\/lars\/spica\/new_kernel\/initramfs/\/home\/USER-NAME\/spica\/voku-kernel\/initramfs/g' ~/spica/voku-kernel/initramfs/initrd.arm.initramfs_list
Here you can add e.g. the version-number etc. ->
cat ~/spica/voku-kernel/initramfs/init.rc | grep build.display.id
Step 5: start compiling
setprop ro.build.display.id "VOKU-kernel v1.5"
Now we can finally start compilation. try "make -j2" or "make -j4" ... if you only want to compile the kernel with the files from initramfs! If you also will compile the modules try the "./build_kernel.sh"-script in the kernel-directory.
Step 6: make a zip-file for recovery
Once finished compiling your kernel you will find in:
the easiest way is to download e.g. my last kernel-version 1.5B and replace the file in the "/xbin"-directory with you own kernel
... this is only a example you can choose different sources on github.
Step 6: use github!
I also have a very low upload BUT you only upload modified sources the other files will be used from a fork so you don't upload all files only the files you touched...
Step 6.1: fork sources
e.g.: gotenks I5700-kernel -> simply press the fork button on github Help.GitHub - Fork A Repo
Step 6.2: get your new fork sources
(replace voku1987 with our username)
git clone https://github.com/voku1987/I5700-kernel-188.8.131.52.git
Step 6.3: committing your changes
Now edit the sources and committing this -> Help.GitHub - Git cheat sheets
and upload only your modified files (also with low upload)
PS: to update the sources try this ->
to add new files try this ->
I hope this tutorial can help someone and please, if you find any mistakes report it ...