[PRO] ToshDroid Linux Kernel (Developers) - TG01 ROM Development

Warning From TheRomMistress:
8. Donations.
We appreciate all donations to xda-developers.com, it keeps our forum online and well maintained. As a user you're allowed to ask for donations in your signature as a thank you for your hard work. However donations up front are not allowed, this forum is about sharing, not about getting paid to do something, that's what your job is for.
Hello guys !!!
So I am endrix and I am trying to port the linux kernel to our Toshiba TG01. I am an h.264 developer who loves linux. Many of you may hate the phone (I do a little too) because of the crappy windows mobile operating system that Toshiba has offered us. Beside the resistive touch screen our phones have a strong processor that is used almost in each smartphone (ok Samsung and Apple are not using snapdragon but is still Cortex A8).
So to the main point!
Firstly is not an easy task and I do not somebody to write in this thread when Android will work with our phones, I truly do not know if I will (or we will) achieve this! Secondly think to contribute as you can to this project, I am here to guide you if you have any questions about how to compile the kernel and if you have any other problem just send me a message or write it in this thread!
My git repository of the TG01 kernel is this one
github.com/endrix/kernel_common
System compilers and libraries:
I used the one given by source.android.com
apt-get install git-core gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev ia32-libs x11proto-core-dev libx11-dev lib32readline5-dev lib32z-dev.
certainly you do not need all of them but is ok to have it
So how can you compile the kernel?
Steps:
Use an Ubuntu Linux distribution or virtualise it with Virtualbox
I am using this cross tools: arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2"
in my system I have created a directory in my /opt folder, to that just do "sudo mkdir /opt/cross"
Now go to the directory with "cd /opt/cross"
now rember where you have download the tar archieve and execute the following command, in this command i have downloaded my tar in /home/endrix/Download: so for my directory I do " tar xjvf /home/endrix/Downloads/gnueabi-i686-pc-linux-gnu.tar.bz2"
Now that we have our cross tools installed in our system is it good to create an eviromental varibale to easy our task of ceoss compiling. do this command "gedit ~/.bashrc" and at the end of the file put this line: export CROSS_TOOLS=/opt/cross/arm-2009q1/bin/arm-none-linux-gnueabi-
now execute this command "source ~/.bashrc" so that you command can be activated for the current command, the next time that you will open another console or reboot the varibale $CROSS_TOOLS will work
This is all for the cross tools
Next step Compile the linux kernel:
Create a directory for example "Projects" in your main directory(home), "mkdir ~/Projects"
Clone the repository of my git address: "git clone github.com/endrix/kernel_common.git"
Now you wait, take a coffe or eat a fruit
now you execute this command in the "kernel_common" directory, "make ARCH=arm htcleo_defconfig"
and then to compile the kernel" make ARCH=arm CROSS_COMPILE=$CROSS_TOOLS Image"
To make the process even faster if you have a multicore system, put -j4 (for 2 cores) or -j16 (if you have an intel iCore7 with 4 cores double threaded), that means, "make -j4 ARCH=arm CROSS_COMPILE=$CROSS_TOOLS Image"
After a while depending you system you will get the kernel image file in the arch/arm/boot directory
So now you have the kernel compiled
Next step test the kernel with Haret:
1) Create the file default.txt with :
set mtype 2675
set ramaddr 0x11800000
set ramsize 0x18C00000
set kernel Image
boot
2)Download My modified version of Haret with TG01 support!
Haret for TG01
3)Create a folder in your sd card --> "ToshDroid and put the Image the haret.exe and the default.txt in it.
4) Finally execute the haret.ext and clik on run!
That's all folks! Now I am focusing in the Memory Map...
PS: sorry for links, As a junior member i cannot give a full url
I will update also my blog too for TG01
endri-bezati.blogspot.com

Hi endrix and welcome to xda-developers
I very much appreciate your work.. i've the same device.. it's a beautiful phone.. with a powerful hardware.. but windows mobile is not worthy of the hardware it runs on.. so we look forward for a release of android!
BTW.. i'd know what do you need to do your work.. can you make a list of thing that you need to accelerate your work? the first thing is compile android kernel.. but next? need you we post results? how we can fix the errors?
Sorry for my english but i'm italian.. and thank you.. hoping to see soon a first version of android..

Image Compiled without errors..
running haret it stops to "Jumping to kernel(custom). and freeze..

isikil87 : Ok! forgot something!
Do
1) make clean
2) git checkout android-msm-2.6.32-tg01
3) make ARCH=arm htcleo_defconfig
4) make -j4 ARCH=arm CROSS_COMPILE=$CROSS_TOOLS Image
actually I am working on the android-msm-2.6.32-tg01 branch

compiled successfully...
boot ok.
jump to image ok.
linux pic visible.ok.
now we need the right address to write memory.

Cool !
isikil87 said:
compiled successfully...
boot ok.
jump to image ok.
linux pic visible.ok.
now we need the right address to write memory.
Click to expand...
Click to collapse
Exactly, the framebuffer is wrong too i think the addresse in the msm_iomap is not correct
#define MSM_RAM_CONSOLE_BASE IOMEM(0xF8010000)

have you dump the memory???

dump ?
isikil87 said:
have you dump the memory???
Click to expand...
Click to collapse
I have run haret with "dump mmu" but is not easy to understand everything, I am really a beginner in this domain I am currently searching for documentation!

I am beginer too. How can I help?
Can you share with us that Image file?

The image file
TruckyBN said:
I am beginer too. How can I help?
Can you share with us that Image file?
Click to expand...
Click to collapse
It will not help you a lot but here is the compiled kernel
megaupload.com/?d=W027CS8P

this is interesting
http://htc-linux.org/wiki/index.php?title=Talk:Tg01

About the code
isikil87 said:
this is interesting
http://htc-linux.org/wiki/index.php?title=Talk:Tg01
Click to expand...
Click to collapse
Actually if you compare my modified code for the tg01 branch you will see that I have done the same modification (I was inspired by this pages too)!

endrix said:
It will not help you a lot but here is the compiled kernel
megaupload.com/?d=W027CS8P
Click to expand...
Click to collapse
Thanks for share.
I already to boot up. But error is (teminating haret due to unhandled exception pc=00017254)
please tell me how to config and boot it. thank so much.
best regard !

nhattuong said:
Thanks for share.
I already to boot up. But error is (teminating haret due to unhandled exception pc=00017254)
please tell me how to config and boot it. thank so much.
best regard !
Click to expand...
Click to collapse
have you downloaded the latest version of haret?
check it http://netripper.com/leo/haret-pre-0.5.3-20100914_124354.exe

isikil87 said:
have you downloaded the latest version of haret?
check it http://netripper.com/leo/haret-pre-0.5.3-20100914_124354.exe
Click to expand...
Click to collapse
Thanks for share.
It is already to boot. But after 10 sec...auto reset.
Then hit HaRet App again...after 10 sec...device reset...
Please teach me more ! thank you very much !
P/S : Wich one Android Version you use ?
Best Regard !

nhattuong said:
Thanks for share.
It is already to boot. But after 10 sec...auto reset.
Then hit HaRet App again...after 10 sec...device reset...
Please teach me more ! thank you very much !
P/S : Wich one Android Version you use ?
Best Regard !
Click to expand...
Click to collapse
that is only an alpha version. it doesn't boot up untill we have the right addresses of nand iomap ram ecc of the device.
regards

isikil87 said:
that is only an alpha version. it doesn't boot up untill we have the right addresses of nand iomap ram ecc of the device.
regards
Click to expand...
Click to collapse
oops ! I understand. Thanks.
Best Regard,

No questions about Android please, this thread is only for the kernel!!!
nhattuong said:
Thanks for share.
It is already to boot. But after 10 sec...auto reset.
Then hit HaRet App again...after 10 sec...device reset...
Please teach me more ! thank you very much !
P/S : Wich one Android Version you use ?
Best Regard !
Click to expand...
Click to collapse
For the moment the kernel has a problem because I have not figured out all the memory addresses and the reset is normal. Now you have to wait for a long time till we achieve to find the memory values. For android is another story if the kernel does not work correctly android will not work!

endrix said:
For the moment the kernel has a problem because I have not figured out all the memory addresses
Click to expand...
Click to collapse
how can we help in reading memory addresses? maybe there is a way that we all could divide work on many tg01 users?

endrix said:
For the moment the kernel has a problem because I have not figured out all the memory addresses and the reset is normal. Now you have to wait for a long time till we achieve to find the memory values. For android is another story if the kernel does not work correctly android will not work!
Click to expand...
Click to collapse
yeap ! i see. Thanks for your great works.

Related

[REF] How to compile your own kernel and initrd for HTC Leo

Kernel compile :
Do it on user not root :
1. Make sure you have an appropriate environment to get the source (git) and to compile the kernel. Install git, gcc, make and libncurses5-dev at least. For Ubuntu based distributions.
apt-get install git-core build-essential libncurses5-dev
2. Create a directory to hold the kernel sources
mkdir ~/htcleo
3. Download the kernel source
cd ~/htcleo
git clone git://git.linuxtogo.org/home/groups/mobile-linux/kernel.git
cd kernel
git checkout -b htc-qsd8k-2.6.29 origin/htc-qsd8k-2.6.29
4. Download and decompress the arm toolchain (64mb)
cd ~/htcleo
wget http://www.codesourcery.com/gnu_too...-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
tar xjf arm-2008q1-126-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
5. Generate the default .config for the kernel(ARCH is case sensitive)
cd kernel
make htcleo_defconfig ARCH=arm
6. Compile
export PATH=~/htcleo/arm-2008q1/bin:$PATH
make Image ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
Find your kernel Image in /htcleo/kernel/arch/arm/boot/
Now you can configure your proper kernel :
mousepad (Xfce) or gedit (Gnome) ~/htcleo/kernel/arch/arm/configs/htcleo_defconfig
cd ~/htcleo/kernel
make mrproper
make htcleo_defconfig ARCH=arm
export PATH=~/htcleo/arm-2008q1/bin:$PATH (must need once time)
make Image ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
Use git pull in ~/htcleo/kernel to update file and recompile to have the last modified on development
Initrd compile :
Need to be root !
1. Download initrd.gz from other HTC compiled
mkdir initrd (or anything else in propely folder nothing else on)
cd initrd (put your initrd.gz here)
gzip -dc initrd.gz | cpio -id
Now you have all file and folder you can touch and modified
Use mousepad or gedit on root
2. Recompile proper
rm initrd.gz (before do a copy for other instance)
find (all name of folder and file) | cpio --create --format='newc' > initrd
Compile source for Arm :
(root user)
On source folder :
#export ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- PATH=(your path)/arm-2008q1/bin:$PATH
#CC=arm-none-linux-gnueabi-gcc ./configure --host=arm-none-linux-gnueabi --target=arm-none-linux-gnueabi
# make
For who want to take time to test and finaly make Android works on HTC Leo.
I thinks all members hav's HTC Leo !!
hey guys..
i really want to use android on my new HD2!
i'm a little-medium (^^) n00b, but spent a lot of time in android on my kaiser.. so i'm not a totally noob, i think.
i can help testing files for you.
so, what do the dev's think, how long did it take to use android on our phones?
greetings
Thanks for the tip, will try it tomorrow and report what I see
wget http://www.codesourcery.com/gnu_tool...ux-gnu.tar.bz2 -O arm-2008q1-126-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
Click to expand...
Click to collapse
On the wget command supplied you have to right click and copy link location and paste that as the wget url or it wont work, the forum has truncated the text with ... in the middle . use the -O afterwards as shown
1. Download initrd.gz from other HTC compiled
Click to expand...
Click to collapse
Im also not quite understanding this, what is other HTC compiled ? Another set of sources with Android?
Thread Edit
You can take any one initrd.gz and modified script on it.
HTC Vogue initrd.gz its the better.
Tigrouzen said:
Thread Edit
You can take any one initrd.gz and modified script on it.
HTC Vogue initrd.gz its the better.
Click to expand...
Click to collapse
Thanks for fixing the wget ..
Cool so i already have another initrd and i hang at the freeing 104k init error .. Are you able to get past this ?
Nice job writing that up.
Personally I use a different toolchain, but if the toolchain you mention works without a problem, then all is well When I used a toolchain from codesourcery I somehow got compile errors as there was no VFP support (maybe I just took the wrong binary).
The toolchain i'm using is in this git repo: http://android.git.kernel.org/?p=platform/prebuilt.git;a=summary and under linux-x86/toolchain/arm-eabi-4.4.0
NetRipper said:
Nice job writing that up.
Personally I use a different toolchain, but if the toolchain you mention works without a problem, then all is well When I used a toolchain from codesourcery I somehow got compile errors as there was no VFP support (maybe I just took the wrong binary).
The toolchain i'm using is in this git repo: http://android.git.kernel.org/?p=platform/prebuilt.git;a=summary and under linux-x86/toolchain/arm-eabi-4.4.0
Click to expand...
Click to collapse
This toolchain works, compiles fine but fails on boot at the 104k error for me .. Not sure how to progress this without further info / debug ..
NetRipper said:
Nice job writing that up.
Personally I use a different toolchain, but if the toolchain you mention works without a problem, then all is well When I used a toolchain from codesourcery I somehow got compile errors as there was no VFP support (maybe I just took the wrong binary).
The toolchain i'm using is in this git repo: http://android.git.kernel.org/?p=platform/prebuilt.git;a=summary and under linux-x86/toolchain/arm-eabi-4.4.0
Click to expand...
Click to collapse
Yes cause you use 2009q3 arm-eabi not contain VFP support maybe not important.. i try with your toolchain and 2008q1 binary
This is one worked with 2008q1 binary
Nice work! When do you think Android will be avaible on HD2?
How should I format the micro SD Card ?
Do I have to create two partitions (one eith FAT to boot and another ext3 to filesystem ?)
Does anyone have a tutorial to configure the sd card ?
My experience format SD card make some mistake and brick some SD card on linux. For now dont do that cause no way and ist not ready to work.
But Android porting hardware its now everything ok, just wait some moment maybe one or two month to see it on HD2.
This test just need put haret, default.txt based on Leo, initrd.gz and Image on sdcard root and executed haret
If you have drivers to every piece of hardware then tell me how did you managed to detect the SD card reader. Because I simply can't.
The developer find right interrupt for hardware on Leo but we dont have definitively realized driver, this is a problem to communicate right with Leo hardware.
If we have main console work then its ok!!
Now just have boot working and freez.
We need wait.
You can maybe look in this thread Martijn Stolk works, 38hours ago he add some instruction on kernel, then its signified we advanced to make Android works.
http://git.linuxtogo.org/?p=groups/mobile-linux/kernel.git;a=shortlog;h=refs/heads/htc-qsd8k-2.6.29
I think 2 months later if everything ok.
Now you dont need formating your sd card just put file on root.
What's about other non-Leo QSD8x50 devices? I tried some of previous NetRipper's kernels, but they didn't work... As I'm completely next to nothing in ARM kernel development, I take someone should port IRQ and GPIO map (If I remember correctly) of respective devices (e.g. neoTouch, Expo, TG01 etc), isn't it?
Or is the kernel universal?
I thinks HTC take's other hardware way and this hardware doesn't have any driver on linux.
HTC just make's driver for Windows mobile and then have realy code source to ported on linux and android.
Or maybe system locked protection !! Like's Archos 5 IT code secure implentation !!
Maybe HTC do it protection hardware cause Microsoft ask him to not porting it on Android !!!
Or marketing way not arrenged HTC to sell HTC Supersonic simillar hardware with Android !!
I hope its not this way, cause no way to ported Android or linux on Leo..
Last issue if there no protection just wait for HTC Supersonic and porting in Leo.
Tigrouzen said:
Last issue if there no protection just wait for HTC Supersonic and porting in Leo.
Click to expand...
Click to collapse
Would love it, with DualBoot in more
I'll donate for Android, I am really excited to get it on our device !
Thank you to all developpers who take time for us !
See you.
Edit : Use "git pull" to update automatically file modified on development
Thanks for developers.
Edit : compile source for Arm

[TOOL/KITCHEN] - Android Builder v.5 (Dead)

This project is no longer being updated. Feel free to use the code.
Android Builder (AB v.5)
kiel123 has joined the AB team!
Thanks to dsixda, Armin Coralic, and cteneyck. I do have permission to reuse their code.
Requirements:
Ubuntu Linux or variant
dsixda's HTC Android Basic Kitchen - http://forum.xda-developers.com/showthread.php?t=633246
In my crazy quest to learn more about Android, I decided to create a companion to dsixda's kitchen that will take some of the drudgery out of downloading and compiling AOSP and the HTC kernel.
Here's what the current menus looks like:
Code:
Select the device that you would like to build for.
1) HTC Droid Eris
a) About Builder
0. Exit
Please enter option number:
and then
Code:
1. Sync AOSP - Cupcake (1.5) repo
2. Sync AOSP - Donut (1.6) repo
3. Sync AOSP - Eclair (2.1) repo
4. Sync AOSP - Froyo (2.2) repo
0. Exit
Please enter option number:
You can follow these two steps, and you will get a freshly compiled, but unsigned ROM in the original_update folder. After running it through the kitchen, it boots up just fine. Of course, most of the hardware doesn't work. That's the part that I am working on now (seriously, I am). I've been working on this for a while, because as I said - this is really about me learning. If I can make a tool that someone finds useful, then great!
Install instructions:
1) download and unzip dsixda's kitchen to whatever directory you want
2) download Android Builder into kitchen's scripts/plugins folder and unzip
3) back out and start the kitchen
4) select 'Run plugin scripts' from Advanced menu and select 'Android Builder'
5) you're there!
NOTE: This will try to install/update all of the packages that it needs, including Java5. Please look at the code so that you know what it's doing. That's just a good general practice with any code that you can actually look at and that you have to run as root...
Future plans:
1) add more kernels (devices)
2) add more vendor trees (goes along with devices)
3) add more repos (CM5, CM6, AOSP Master)
I hope someone finds this useful, and feel free to post useful suggestions/bug reports.
DOWNLOAD - (https://github.com/gnarlyc/android_builder)
CHANGELOG -
v5. - kiel123 re-wrote v.4 as a plugin to dsixda's kitchen with me testing afterward, minor fixes, removed Java6 as no longer needed by kitchen
v.4 - re-wrote to add structure to support more devices in the future
added option for Cupcake, Donut, and Froyo
added .config files that enable touchscreen in kernel by default
v.3 - unreleased build
v.2 - corrected misspellings in code and dialogs
added sudo to launch setup script (Still need to sudo bash first. Sorry.)
v.1 - initial release
Very nice. I have been doing the same. I have used darchstar's post here as the basis of my work. But, I am always glad to look how others are doing things. Thanks for the post.
arockj said:
Very nice. I have been doing the same. I have used darchstar's post here as the basis of my work. But, I am always glad to look how others are doing things. Thanks for the post.
Click to expand...
Click to collapse
Thanks for the thanks! I don't quite get the vendor tree thing, but I just need to look at it again a few times. And, that's where I'm at. It would be really neat to be able create a working AOSP ROM from scratch with minimal manual intervention. It might not be possible, but I haven't found that out yet. (But wait! If you can do it manually, it can be scripted. Right?)
there's typo in your install script
look for line: android_builder*
should be android-builder*
and your install script should use mv command instead of cp to avoid files duplication
EDIT: also you should use sudo command along with ./ab_setup script or include within script as well.
When i ran ./abmenu and i get this message
Code:
Please copy 'menu-kd' to the root of your kitchen folder with 'menu'
menu-kd?.... don't you mean abmenu? turned out it was looking for menu file which i had it renamed to kitchen_menu but I fixed that on my part and all is working well.
Dont let any of my criticism scare you away, I can see there's a lot of potential use for this scripts, great start by the way.
firestrife23 said:
there's typo in your install script
look for line: android_builder*
should be android-builder*
and your install script should use mv command instead of cp to avoid files duplication
EDIT: also you should use sudo command along with ./ab_setup script or include within script as well.
When i ran ./abmenu and i get this message
Code:
Please copy 'menu-kd' to the root of your kitchen folder with 'menu'
menu-kd?.... don't you mean abmenu? turned out it was looking for menu file which i had it renamed to kitchen_menu but I fixed that on my part and all is working well.
Dont let any of my criticism scare you away, I can see there's a lot of potential use for this scripts, great start by the way.
Click to expand...
Click to collapse
I renamed all of the scripts at the last minute and thought that I had them fixed. I'll make the corrections and repost. The goal is to get this thing working well. Your criticism is just more motivation. Thanks!
I'm new to all this but I would love this to work with Froyo source.
Geo411m said:
I'm new to all this but I would love this to work with Froyo source.
Click to expand...
Click to collapse
The current 'internal' build works with Cupcake (1.5), Eclair (2.1), and Froyo (2.2). It's not ready to release though. Give me another week or two. I'm working on proprietary bits now, so that you get a more usable ROM from the start.
Although from your sig, it appears that you don't have an Eris, so you probably don't care much about it's proprietary bits. If you want it to get Froyo instead of Eclair, you can just change 'eclair' to 'froyo' in the script that creates the repo.
I'm with you on Froyo. I have a feeling in a month or two very few people will want to run a pre-Froyo ROM. It's really nice.
rm error on install
i keep getting "rm: cannot remove './bkup': No such file or directory"
the file is there untill i run the ./install script then it disappears and shoots me an error any help would be appriciated
Sjflowerhorn said:
i keep getting "rm: cannot remove './bkup': No such file or directory"
the file is there untill i run the ./install script then it disappears and shoots me an error any help would be appriciated
Click to expand...
Click to collapse
That files was used by me while developing the code. It's not needed. I'll fix the install script for v.5, but if you really want to fix the script now... Just remove the line -
'rm ./bkup'
from the 'install' script
You should still be able to start Android Builder by typing './abmenu', as long as it's in the same folder with the kitchen's menu. The error shouldn't matter.
gnarlyc said:
That files was used by me while developing the code. It's not needed. I'll fix the install script for v.5, but if you really want to fix the script now... Just remove the line -
'rm ./bkup'
from the 'install' script
You should still be able to start Android Builder by typing './abmenu', as long as it's in the same folder with the kitchen's menu. The error shouldn't matter.
Click to expand...
Click to collapse
k thanks i think it worked the same even with the error but got it =)
Sjflowerhorn said:
k thanks i think it worked the same even with the error but got it =)
Click to expand...
Click to collapse
Good deal. Let me know how it goes.
gnarlyc --
Have you thought of making this into a .plugin file that can be placed in the scripts/plugins folder of the HTC Android Kitchen? Then that way you won't need to update your scripts each time I update my kitchen
In my thread I could provide a link to your tool, so that people can add that plugin if they want.
dsixda said:
gnarlyc --
Have you thought of making this into a .plugin file that can be placed in the scripts/plugins folder of the HTC Android Kitchen? Then that way you won't need to update your scripts each time I update my kitchen
In my thread I could provide a link to your tool, so that people can add that plugin if they want.
Click to expand...
Click to collapse
The thought has occurred to me.
Give me a bit. A link in your thread would be great. It might even motivate me to add more devices. Getting stuck on adding Eris proprietary bits has lead me down the road of making a ROM (http://forum.xda-developers.com/showthread.php?t=725447) and documenting the process. I'll get back to Android Builder soon though.
Ok, so...
TO-DO
-------
1) rewrite AB as a plugin to dsixda's HTC Android Kitchen
2) add proprietary bits for Eris
3) add more devices
4) add CM repos
5) add Gingerbread repo
6) add compatibility with more distros
i am getting line 28: update-java-alernatives: command not found?
lord194409 said:
i am getting line 28: update-java-alernatives: command not found?
Click to expand...
Click to collapse
Interesting... I've tested from a freshly installed Ubuntu installation several times. It should install everything you need.
You could try 'update-alternatives --config java' and let me know what it says. You could also look for a file called 'setup_ran' in the root of the Kitchen, and delete it. Start './abmenu' after that and try again.
thanks for answering. Could the problem be that i installed it on cygwin.
lord194409 said:
thanks for answering. Could the problem be that i installed it on cygwin.
Click to expand...
Click to collapse
Yes. Android Builder will not work under cygwin. I don't know that it ever will. That's on the TO-DO list, but it's so far down that it's not on the posted TO-DO list.
I've only tested under Xubuntu 10.04 and minimal Ubuntu 10.04.
If you happen to work it out on cygwin, let me know! I'm sure others would be happy to have the option. Heck, I might even be. I'm mainly using Ubuntu because of AB anyway. (Although, it is kind of growing on me.)
thanks i will look in to it.
Sent from my Eris using XDA App
just wanted to let you know that it didn't work for me. It runs, gives some errors and outputs a update.zip called AOSPbase but the file is only 1.1kb in size.
Geo411m said:
just wanted to let you know that it didn't work for me. It runs, gives some errors and outputs a update.zip called AOSPbase but the file is only 1.1kb in size.
Click to expand...
Click to collapse
make sure you have java5 and java6 jre/jdk installed. it should work then. i had a similar issue the first time through... took it literally 10hours plus, then output was the 1.1k AOSPBase.zip file.
manually installed all java components, and everything worked perfectly then (and took half the time)

CyanogenMod 6 installation guide !

Hey guys.
I'm a young developer from germany and today I'm gonna show you how to compile CyanogenMod 6 (based on 2.2 FROYO) for our GT-i5800.
I'd do these things on my own and upload the finished rom, but I got very little amount of free time at the moment...
Anyways, I've prepared a script for you that does it all automatically :
- getting required packages
- getting CyanogenMod's source code
- sync the repo
- pull the required files from our phones
- getting the RomManager
SO HERE ARE THE STEPS :
| THIS GUIDE IS FOR UBUNTU ONLY |
STEP 0 . Ensure ADB is working correctly.
Run
Code:
./ adb devices
and see if there is something like
(NUMBERS xxxxxxxx) device
if so, proceed to step 1!
STEP 1 . Make the script executable.
Run
Code:
[PATH TO THE FOLDER CONTAINING THE SCRIPT]chmod a+x CyanogenMod.sh
STEP 2. Run the attached CyanogenMod6.sh.
STEP 3. Flash the generated update.zip via CWM recovery
[big thx to mumbzover !]
If there are errors while running the script, please post a detailed error report in here.
AND HAREE, please move this to the dev section. Cause i cannot post there
Hi..did you manage to port it with everything working?
Well, what about the apollo device ?
No ... saidly I haven't tried this on my own because my free time is very limited at the moment.
But I want you guys to try it out !
@Dharamg3 I think it should work with both, GT-i5800 and GT-5801 apollo.
I will try to get my own hands on this in a few days ...
BTW I'm building on Ubuntu 10.04 in VMWare with Mac OS Lion as host.
rayman33 said:
No ... saidly I haven't tried this on my own because my free time is very limited at the moment.
But I want you guys to try it out !
@Dharamg3 I think it should work with both, GT-i5800 and GT-5801 apollo.
I will try to get my own hands on this in a few days ...
BTW I'm building on Ubuntu 10.04 in VMWare with Mac OS Lion as host.
Click to expand...
Click to collapse
mate, sorry to disappoint you, but this method wont work...it is not so easy
you need to build an apollo device from scratch...marcellusbe is already working on it, and is at a very good point already...
dharamg3 said:
mate, sorry to disappoint you, but this method wont work...it is not so easy
you need to build an apollo device from scratch...marcellusbe is already working on it, and is at a very good point already...
Click to expand...
Click to collapse
as it's froyo (2.2) based it might work, marcellusbe is working on CM7 with gingerbread (2.3) which is far more work.
sharukins said:
as it's froyo (2.2) based it might work, marcellusbe is working on CM7 with gingerbread (2.3) which is far more work.
Click to expand...
Click to collapse
Well he's working on cm6.2 atm
Good initiative but as dharam said building the apollo device is the hardest part
cdesai said:
Good initiative but as dharam said building the apollo device is the hardest part
Click to expand...
Click to collapse
i dont think.. coz it is cm6 , not cm7 !! may b it can easily feasible .. :/
ranadip.bswas said:
i dont think.. coz it is cm6 , not cm7 !! may b it can easily feasible .. :/
Click to expand...
Click to collapse
CM6 is a very nice Rom as well...
Talking bout easy feasibility, if it was, we'd have got it long ago..
Porting Just a theme involves tons of efforts, this is a full Cyanized AOSP rom !
Rapier07 said:
CM6 is a very nice Rom as well...
Talking bout easy feasibility, if it was, we'd have got it long ago..
Porting Just a theme involves tons of efforts, this is a full Cyanized AOSP rom !
Click to expand...
Click to collapse
bro , i meant it may b more easy than portin cm7 ..
ranadip.bswas said:
bro , i meant it may b more easy than portin cm7 ..
Click to expand...
Click to collapse
Yyep .. easier than cm7 but yeah, difficult..
I'm Excited to get my hands on CM froyo
This rom actualy work?
Sent from my GT-I5800 using XDA App
So it is working on I5800 ? i can't try becouse i have windows on my pc
wareeezer said:
So it is working on I5800 ? i can't try becouse i have windows on my pc
Click to expand...
Click to collapse
Not working for our phone, haven't you read the thread? There are a few devs working to get CM6 done, just wait
ok I'm waiting....
now I need to wait 10 years "repo sync" and I can Finally start build the rom. If it will work I tell you.
btw. I had a lot of problems with "repo" it wont to work, always command not found, so I needed to run commands manually with edited path to "repo".
My guide. (It worked for me to 14th. step)
If you guys going to install ubuntu you need to install sun-java6-sdk package.
sudo apt-get update (without this line you can not download java sdk)
sudo apt-get install sun-java6-sdk
sudo apt-get install curl
1. download android SDK save it somewhere. (e.g.: /home/Erik/andSDK)
2. open terminal, locate your folder with android SDK with tools folder (e.g.: cd /home/Erik/andSDK/tools)
3. type this commands into terminal: sudo chmod 777 ./android now type ./android now you can see the user interface of android SDK and emulator. Chose Available packages install every package (third-party too)
4. if you have every package, close the window, and return to the terminal
5. type: cd ../platform-tools
6. now place the CyanogenMod6.sh to this folder (/home/Erik/andSDK/platform-tools)
7. run the script: ./CyanogenMod6.sh
8. If it ask you for yes or no, type "y" for yes "n" for no.
9. You will get error (command repo not found)
10. Now you need to have somewhere 2 folders (android and bin) in bin folder you need to have file called repo. transfer this file into "~/android/system/" folder.
11. run again CyanogenMod6.sh
12. it will do something really fast, and if it ends type ./repo sync -j16 (if you are in ~/android/system/ folder)
13. if I am right and you are doing everything right you need to wait 10 years
14. now at 21:51 I got message like this: sync was stopped for some problems (after 20minutes of waiting)
Have Fun
EDIT -° Console result from step 14.
From git://github.com/CyanogenMod/android_device_samsung_bmlunlock
* [new branch] master -> github/master
Fetching projects: 17% (36/210)
error: Exited sync due to fetch errors
[email protected]:~/android/system$
Click to expand...
Click to collapse

Championswimmer's Ultimate HOW-TO

after numerous requests here we go!!!
no it's not complete yet, just starting...
firstly i'll just link up all threads from where i took collected my info, and then i'll start wiriting my how-to
it'll take time as my school and entrance exams are main priority at the moment but i'll do it in bits and pieces and i'll manage to pull it off before you x10 dies off .. ha ha ha
==========================================================================================================
SIMPLE GUIDE TO COMPILE KERNEL FOR X10i/X10a
=====================================================================================================
COMPILE AOKP FOR ANY XPERIA PHONE
=====================================================================================================
REFERENCE TO COMPILE AOSP/AOKP/CM7/CM9 FOR X10i/X10a
==========================================================================================================
firstly credits : >
1. DoomLord -> whose tools and info thread are just awesome
2. Zdzihu -> the biggest ever dev for x10 and for doing impossible feats
3. Freexperia Team -> for supporting this device for 2 years
4. Spaarc -> for his guide and his vast knowledge (guys!! this dude is 1 yr younger than me!!)
5. Azuzu -> for his awesome windows based tools
6. Androxyde -> flashtool and awesome shell scripts
7. Colossus -> for being the best mod ever !!! (yes i mean it buddy) and for guiding me a lot
8. Sahibunlimited -> for being me buddy and a really good friend to everybody here
9. GregBradley -> for being having the most useful signature in xda (and having helped me out when i was a noob)
10. LzVebz -> Pestering me to write this
phew!!! hope that's all?? more left?? please pm me, i'lll add you
EDIT
11. pvyParts -> for showing how to work on apk files
12. iridaki -> for being helpful and encouraging and pepping me up for all the good work i did and mostly for being an elder sister
13. ~Pilot~ -> for keeping xda clean
14. TAL333 -> for standing by me and believing in me
So firstly the threads that I read and YOU SHOULD PLEASE GO THOUGH ONCE before reading my Howto
spaarc's porting guide
doom's guide 1
doom's guide 2
doom's guide 3
doom's all in one info thread
doom's kernel.sin and ftf creator
doom's kernel.sin unpacker
dsixda kitchen (for "cooking" roms)
using android kitchen for xperia devices
http://forum.xda-developers.com/showthread.php?p=12875
Ok so as they say "safety first"
Let me give you your CRASH HELMET
It is said that x10 is UNBRICKABLE, though that is true but not hard and fast rule. Jerpelea and Doomlord have bricked x10 devices before and it's not all that impossible. Still, if you keep care of following things, you'll never brick your phone
1. NEVER DISCONNECT USB CABLE while flashing/bootloader unlocking/pccompanion upgrade is going on
2. Be extremely careful while using the_laser or 9Lukas5's unlock procedure. It changes device partition and mapper modules so they are delicate ares and can brick your device if procedure is not followed
3. DO NOT PANIC, THINGS CAN BE SET RIGHT. BE CALM, BE PATIENT, ASK FOR HELP AT XDA
=======================================================================================================================
Ok so, there can be bad flashes or whatever..... what to do if device does not boot up??
1. If the problem is about RED flashing led, then just plug your phone into a charger and wait over night it's a low charge problem. Once charged, all will be ok
2. If you face boot loop and you just do not know what to do (i.e. you cannot go to recovery too) then do this
a.) either download PC companion and update/upgrade your phone
OR
b.) download latest flashtool and flash a 2.1 for 2.3.3 firmware (that you get in .ftf format) that will set you on track
ok so to tell a few things first....
please do not pm me.regarding this.
ask any questions here.
i or any other member would definitely help
and dont get impatient.... I'm busy...so it'll take time to complete the guide
Sent from my X10S using xda premium
Finally it's here!!! Thanks man, I've been waiting for this
LzVebz said:
Finally it's here!!! Thanks man, I've been waiting for this
Click to expand...
Click to collapse
I've not yet started....feeling too lazy...but dont worry...in a week or two it'll be complete
Sent from my X10S using xda premium
Alright pretty dumb question feel free to shoot me. If I take an system ui apk and framework apk from say arc and just change it with my existing system ui n framework will I be getting the same theme of Sony arc.
Sent from my X10S using XDA
stanzzzzz said:
Alright pretty dumb question feel free to shoot me. If I take an system ui apk and framework apk from say arc and just change it with my existing system ui n framework will I be getting the same theme of Sony arc.
Sent from my X10S using XDA
Click to expand...
Click to collapse
maybe yes with systemui
DEFINITELY NOT with framework.
the framework res is not just the ui.
it defined the whole Android system...
it just cannot be ported like that....lol
@everyone
i won't shoot if you ask dumb questions.
you can ask dumb questions if you wish to.
that's the way we learn
Sent from my X10S using xda premium
Really happy to see someone doing this, thanks CS, may I suggest adding dooms guide to create update/amend scripts? I am sure you'll get to it! Best if luck with your exams too.
Sent from my X10i using XDA
[email protected] said:
Really happy to see someone doing this, thanks CS, may I suggest adding dooms guide to create update/amend scripts? I am sure you'll get to it! Best if luck with your exams too.
Sent from my X10i using XDA
Click to expand...
Click to collapse
never heard of that guide
I'll search and see....
i learnt amend and edify on my own by looking through various zip files....ha ha ha.
btw the dsixda kitchen makes edify/amend scripts automatically
Sent from my X10S using xda premium
championswimmer said:
maybe yes with systemui
@everyone
i won't shoot if you ask dumb questions.
you can ask dumb questions if you wish to.
that's the way we learn
Sent from my X10S using xda premium
Click to expand...
Click to collapse
Excellent! In which case, can you answer this question?
http://forum.xda-developers.com/showthread.php?t=1574805
blueowl0708 said:
Excellent! In which case, can you answer this question?
http://forum.xda-developers.com/showthread.php?t=1574805
Click to expand...
Click to collapse
decompile settings.apk and go through the xml files you get and play around with them a little....
Sent from my X10S using xda premium
this one
Ok, so lets get to our stuff fast
Her we begin with some info about how a ROM works
when cooking/porting roms, you are concerned with only a few folders
download any randon ROM zip and unzip it and see what it contains
1. /system/app -> this folder contains all apk files of apps
2. /system/framework -> this folder contains lots of .jar files that defines how the base operating system will run and function
3. /system/lib -> lots of .so files that are like drivers (yep .dll files in windows), these specify how the software communicates with various hardware components
4. /system/etc -> very dangerous folder contains lots of important configurations
5. /system/etc/permissions -> these contain lots of xml files that are required to define how the .jar files in framwork folder will work
ok so i'll elaborate point 2 and 5 a little more taking example of the panorama beta app by SE. it requires the com.sonyericsson.android.seee.jar file in framework folder to work but if you just keep the jar file, it'll not work. you need to sort out its permissions too and for that you need to put com.sonyericsson.android.seee.xml file in permissions folder
Click to expand...
Click to collapse
also the etc folder contains two some files called
gps.conf (which defines which gps server the device will use)
hosts (this defines which websites will be blocked .... yes that is your adblocker file )
apns.xml (which defines your apn configuration)
screwing up these files can cause you internet/gps/data traffic problems. also intelligent editing of these fils can give you better gps/data too
Click to expand...
Click to collapse
hey champ!
First I'd like to thank you very much for this nice guide and for your kernel. With latter u saved my ass. Was on Doom's with FeraLab and phone reboots sometimes Now it's flying!!!
But I'm fan of good design. And please don't hit me, but I'd like to change the boot-logo of your kernel is there any way? Or do u have any nice guide to change logo?
Would be awesome!!!
Question
Hi champ,
Does THIS also work for X10?
LzVebz said:
Hi champ,
Does THIS also work for X10?
Click to expand...
Click to collapse
not precisely.
for the perfect repacking script, see www.github.com/championswimmer/kCernel-goro
inside build-bootimg folder
Sent from my X10S using xda premium
championswimmer said:
not precisely.
for the perfect repacking script, see www.github.com/championswimmer/kCernel-goro
inside build-bootimg folder
Sent from my X10S using xda premium
Click to expand...
Click to collapse
Thanks!
I've one question left I think
I'm currently on Windows 7 ultimate, and I have 1 TB left on drive D (which is empty) My question is.. Is there a way to Dual-boot Windows & ubuntu without wubi?
Thank u very much again
Compiling kernel
So letme tell you how a kernel for x10 can be compiled
1. install ubuntu (through wubi or in vmware will also do) but i prefer on a separate partition.
2. Install the following packages
git-core gnupg sun-java6-jdk flex bison gperf libsdl-dev libesd0-dev libwxgtk2.6-dev build-essential zip curl libncurses5-dev zlib1g-dev
here's how you go about doing it
Code:
sudo apt-get install git-core gnupg flex bison gperf libsdl-dev libesd0-dev libwxgtk2.6-dev build-essential zip curl libncurses5-dev zlib1g-dev
sun-java6-sdk is no more officially available through ubuntu repositories
so you will need a workaround.... so here are some helpful articles
http://www.gaggl.com/2011/10/installing-java6-jdk-on-ubuntu-11-10/
http://superuser.com/questions/353983/how-do-i-install-the-sun-java-sdk-in-ubuntu-11-10-oneric
http://softwareinabottle.wordpress.com/2011/11/17/install-sun-jdk-6-on-ubuntu-11-10/
In case you are on a 64-bit version of ubuntu, (btw i strongly recommend using a 32 bit version for android development as you'll face various problems with 64-bit at various stages) you'll need these packages too
ia32-libs lib32z1-dev lib32ncurses5-dev gcc-multilib g++-multilib​
3. Next you'll need a cross-compiler.
a cross compiler is used to compile for a different architecture than from the one you are currently working on. in this case you are either on a i686 or amd64 pc while the kernel you are compiling is for an ARMv7 processor.
for ubuntu, getting the Linaro GCC cross compiler for arm is getting as easy as
Code:
sudo apt-get install gcc-arm-linux-gnueabi
4. Now you are pretty much set up to compile kernels. Next we need sources.
So let me link you up to the most common available ones
Sony Ericcsoon Official Kernel Sources for 3.0.1.G.0.75 (gingerbread firmware)
Sony Ericsson Official Kernel Sources for Eclair Firmware
FreeXperia Kernel For ICS
FreeXperia Kernel for GingerBread
DoomKernel (this is my forked repo)
*** i'll update this list later (there are dozens of kernels for x10, all have their sources, i guess for now, this is enough)
5. So the source you have downloaded will be either a tar or zip archive. Using archiver, extract it into a directory of your liking.
6. Open terminal and 'cd' into the kernel directory. The kernel directory is the one which contains the folders arch, block, crypto, firmware, drivers .....
for compiling kernel you need to be in the root of this direcrory.
7. So here are a few codes that will get your kernel compiled
To clean source directory : -
Code:
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make clean
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make distclean
To get default configuration
Code:
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make semc_es209ra_defconfig
if you are compiling FXP kernel then instead of semc_es209ra_defconfig you need to write fxp_es209ra_defconfig , and likewise for DoomKernel you need to use doom_x10_defconfig
To configure the kernel
Code:
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make menuconfig
inside general setup you can name your kernel
and inside power management setup you can setup which CPU governors will be present and which will be default
do not mess to much with the driver setups or with "kernel hacking" area....
do not touch things that you have no idea about
Finally... to compile the kernel
Code:
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make
If all goes well, you'll get this message
Kernel: arch/arm/boot/Image is ready
Kernel: arch/arm/boot/zImage is ready
If you get stuck in between, nothing to fret about. Just post here what problem you faced, amd me or some other helpful soul will help you out
8. I know you are thinking "whew!! are we done??"... ha ha ha!! no buddy!! not yet... much more work to do.
Firstly from you kernel directory go to arch/arm/boot (using a file explorer, not a terminal) and inside you'll find a 2~3 MB sized file called zImage. Copy that file into a separate folder where you'll stach all your finished works.
9. Now we need to compile the wifi modules.
It is imperative to note here that wifi modules should be compiled immediately after kernel has been compiled. DO NOT run "make clean" or "make distclean" commands in the kernel folder before wifi modules have been compiled
Click to expand...
Click to collapse
For compiling wifi, you'll need the "vendor" folder (which is there in official sony kernel sources but not present in Doom's or FXP's repo). So if you need just the vendor folder, you'll HAVE TO download the official kernel sources too.
in terminal 'cd' to vendor/atheros/wlan/host/ folder
edit the localmake.linux.inc file using a text editor
Code:
sudo gedit localmake.linux.inc
edit the line ATH_CROSS_COMPILE_TYPE := arm-eabi- to ATH_CROSS_COMPILE_TYPE := arm-linux-gnueabi-
also in the line
# ATH_LINUXPATH := < kernel source path >
remove the # (uncomment it) and insert the appropriate kernel source path (the folder that contains arch, crypto, firmware, drivers etc folders.
now to compile wifi modules, run this code
Code:
ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- KERNEL_DIR=/path/to/kernel make
of course, in place of "/path/to/kernel" type the actual path to kernel on your pc
this will get your wifi module compiled
go to the folder
vendor/atheros/wlan/host/.output/QUALCOMM_ARM_NATIVEMMC_BSP_REV=3240-SDIO/image/
and you'll find a file ar6000.ko
transfer that file to the place where you kept your zImage safely earlier.
10. PHew!! done?? ha ha .. no dude.. still not...more work left
now to pack things up, you'll need a ramdisk.
so lets steal a ramdisk from a already working kernel (for stock kernel take stock ramdisk, for cm7/cm9 take respective ramdisk)
take any kernel and unpack it using instructions given here
the file ending with xyz.cpio.gz is the ramdisk. rename the file into "ramdisk" (without any extension) and put this file into the folder where you kept your zImage and wifi module.
Now transfer all these three files into a folder which is accessible from your Windows partition (oops... yeah... without windows you cannot finish this job)
Rest of the steps that follow are to be done on Windows (i have not tried on WINE)
rename zImage to "image"
now using this tool (courtesy DoomLord) pack your ramdisk and image into a flashable .ftf file
also make a copy of the file ar6000.ko and name it wifi.ko
both these ar6000.ko and wifi.ko files are supposed to be in the folder /system/lib/module of your mobile (please create appropriate flashable zip for the same)
===============================================================================================================
If you found this Guide helpful, please remember to press the thanks button ;P
================================================================================================================
LzVebz said:
Thanks!
I've one question left I think
I'm currently on Windows 7 ultimate, and I have 1 TB left on drive D (which is empty) My question is.. Is there a way to Dual-boot Windows & ubuntu without wubi?
Thank u very much again
Click to expand...
Click to collapse
send me a screenshot of you disk manager (start->computer management -> disk management)
then i'll tell you how you can set it up easily

[GUIDE] Build Your Own Android Kernel{Easiest and Fastest Way] [Using The NDK]

This is the quickest and easiest way to build your own Kernel using the Android NDK
Note:I will be reffering to the following
yourusername=the username that you are logged in to
devicecode=The codename for the device you are building a kernel for(Google it on what is the code name
Click to expand...
Click to collapse
Note:I am only showing you how to make it to be flashed via CWM. If you wan't a tuttorial on how to make a boot.img comment and i will make it.
What you will need
Ubuntu 12.04 or newer
A lot of patience
Click to expand...
Click to collapse
Step 1:Installing the required files
Open a terminal and type the following (copy-paste)
Code:
sudo apt-get install -y build-essential kernel-package libncurses5-dev bzip2
This will install the packages you need
Download the kernel source code for your device (This is important. We are going to build the kernel from this)
For HTC http://htcdev.com
For Samsung http://opensource.samsung.com/
Click to expand...
Click to collapse
Find your device and click Download
Download The NDK
Move the NDK and your device Kernel source code in your home folder
Extract both the NDK and your kernel source code
Rename the folder were you have the NDK installed to NDK. And rename the folder where you have the kernel installed to Kernel
Now we are ready to build.
Step 2:Tweaking the kernel
Navigate to the kernel folder
Code:
cd /home/[COLOR="red"]yourusername[/COLOR]/Kernel
Next we need to point the NDK tools to the kernel folder
Code:
export CROSS_COMPILE=/home/[COLOR="red"]yourusername[/COLOR]/NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-
We've pointed the NDK tolls and now we can use the NDK to tweak the kernel
Next we need to clean the previous work just incase:
Code:
make clean && make mrproper
If everything goes well you are good to go. If you have an Error(s) then something is wrong.
Now we are ready.
Next we need to add the kernel features to the NDK so we can modife them
Firs open your kernel source code folder go to arch/arm/configs
Here you will all the configs.
We need only one. Find that. It is called:Yourdevicecode_somethingbalblabla.defconfig
Rename it to maker.defconfig
Now type this in your terminal
Code:
make maker.defconfig
Now we need to tweak those configs.
Code:
make menuconfig
A user interface will pop out showing you all the tweaks you can do. I am not going to show you whow to use it. Google it(Sorry don't have that enough space)
When you are ready close the UI and click SAVE
Step 3 Building
So we tweaked the Kernel and we are ready to build.
make -j# ARCH=arm
Click to expand...
Click to collapse
Note:The # means the number of CPU cores +1. For example my device has a quad core CPU and I will type
Code:
make -j5 ARCH=arm
This will build the Kernel. It will take about 10 minutes.
Step 4: Finalizing
Now that kernel is ready you will need to find a kernel flashable zip for your device(Just google it)
Download the zip file and leave it in your home folder.
Now got to your kernel source and go to arch/arm/boot and copy zImage
Paste your Zimage to the zip file and replace it.
Now we need the WI-FI modules otherwise your WI-FI will not be working
Go to the Kernel source code folder and go to driver/net/wireless/bcm4329_204 and copy bcm4329.ko
Got the zip file go to the System folder and replace it's bcm4329.ko with your bcm4329.ko
You are ready all you need to do is flash it.
mmm..interesting...i always build without the ndk,but simpy sdk.what's the advantages?
and i usually do the git clone to download all the sources,in my case nexus7 and maguro.
thanks for this!
Well i am just waiting for Samsung to release JB sources for N7000 to start learning on how to create my own kernel
This is a pretty good base! Thanks
Sorry if this is a stupid question but do we need 64 bit like we do for ROM compiling, or will this work fine for 32 bit (I'm running Ubuntu 12.10 32 bit). Also, roughly how much is there to download? Thanks
:good: Thanks! I'm use Ubuntu 10.04 64 bit don't know if can?
HTCDreamOn said:
Sorry if this is a stupid question but do we need 64 bit like we do for ROM compiling, or will this work fine for 32 bit (I'm running Ubuntu 12.10 32 bit). Also, roughly how much is there to download? Thanks
Click to expand...
Click to collapse
I am not sure. I think you can on 32 bit try it the download takes all together about 500 MB
TheWizardOfROMs said:
I am not sure. I think you can on 32 bit try it the download takes all together about 500 MB
Click to expand...
Click to collapse
Thanks, do you know how large all the files are once installed on the system (you might have guessed I'm slightly short of space atm)
HTCDreamOn said:
Thanks, do you know how large all the files are once installed on the system (you might have guessed I'm slightly short of space atm)
Click to expand...
Click to collapse
About 700 MB
sert00 said:
mmm..interesting...i always build without the ndk,but simpy sdk.what's the advantages?
and i usually do the git clone to download all the sources,in my case nexus7 and maguro.
thanks for this!
Click to expand...
Click to collapse
What are you building? If a whole ROM like AOSP,AOKP,PA or CM then they typically bundle the toolchain/kernel with the source, making this totally unneeded.
---------- Post added at 12:18 PM ---------- Previous post was at 12:17 PM ----------
HTCDreamOn said:
Sorry if this is a stupid question but do we need 64 bit like we do for ROM compiling, or will this work fine for 32 bit (I'm running Ubuntu 12.10 32 bit). Also, roughly how much is there to download? Thanks
Click to expand...
Click to collapse
No 32-bit is fine, just install the right libraries. I actually believe that you can compile a ROM on 32-bit as well.
Self-Plug http://forum.xda-developers.com/showthread.php?t=1748297
Also just to warn users, the above defconfig convention is just that, a convention. The author of a kernel can name the defconfig whatever they want, so it is something to keep in mind.
Sent from my SCH-R950 using Tapatalk 2
thewadegeek said:
What are you building? If a whole ROM like AOSP,AOKP,PA or CM then they typically bundle the toolchain/kernel with the source, making this totally unneeded.
---------- Post added at 12:18 PM ---------- Previous post was at 12:17 PM ----------
No 32-bit is fine, just install the right libraries. I actually believe that you can compile a ROM on 32-bit as well.
Self-Plug http://forum.xda-developers.com/showthread.php?t=1748297
Click to expand...
Click to collapse
i builded some kang rom for personal use,but lately only kernels (for my nexus devices and 2 emebedded system board like in my sig.
Thanks for the guide, but unfortunately I am getting errors during compilation:
Code:
make -j3 ARCH=arm
CHK include/linux/version.h
CHK include/generated/utsrelease.h
HOSTCC scripts/kallsyms
HOSTCC scripts/bin2c
CC scripts/mod/empty.o
arm-eabi-gcc: No such file or directory
Is your PATH set correctly?
make[2]: *** [scripts/mod/empty.o] Error 2
make[1]: *** [scripts/mod] Error 2
make[1]: *** Waiting for unfinished jobs....
make: *** [scripts] Error 2
I am trying to compile the Andromadus 3.0 kernel for HTC Vision, I'd really appreciate some help. I'm using Ubuntu 12.10 32 bit and the Android NDK.
TheWizardOfROMs said:
This is the quickest and easiest way to build your own Kernel using the Android NDK
Note:I will be reffering to the following
Note:I am only showing you how to make it to be flashed via CWM. If you wan't a tuttorial on how to make a boot.img comment and i will make it.
What you will need
Step 1:Installing the required files
Open a terminal and type the following (copy-paste)
Code:
sudo apt-get install -y build-essential kernel-package libncurses5-dev bzip2
This will install the packages you need
Download the kernel source code for your device (This is important. We are going to build the kernel from this)
Find your device and click Download
Download The NDK
Move the NDK and your device Kernel source code in your home folder
Extract both the NDK and your kernel source code
Rename the folder were you have the NDK installed to NDK. And rename the folder where you have the kernel installed to Kernel
Now we are ready to build.
Step 2:Tweaking the kernel
Navigate to the kernel folder
Code:
cd /home/yourusername/Kernel
Next we need to point the NDK tools to the kernel folder
Code:
export CROSS_COMPILE=/home/yourusername/NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-
We've pointed the NDK tolls and now we can use the NDK to tweak the kernel
Next we need to clean the previous work just incase:
Code:
make clean && make mrproper
If everything goes well you are good to go. If you have an Error(s) then something is wrong.
Now we are ready.
Next we need to add the kernel features to the NDK so we can modife them
Firs open your kernel source code folder go to arch/arm/configs
Here you will all the configs.
We need only one. Find that. It is called:Yourdevicecode_somethingbalblabla.defconfig
Rename it to maker.defconfig
Now type this in your terminal
Code:
make maker.defconfig
Now we need to tweak those configs.
Code:
make menuconfig
A user interface will pop out showing you all the tweaks you can do. I am not going to show you whow to use it. Google it(Sorry don't have that enough space)
When you are ready close the UI and click SAVE
Step 3 Building
So we tweaked the Kernel and we are ready to build.
Note:The # means the number of CPU cores +1. For example my device has a quad core CPU and I will type
Code:
make -j5 ARCH=arm
This will build the Kernel. It will take about 10 minutes.
Step 4: Finalizing
Now that kernel is ready you will need to find a kernel flashable zip for your device(Just google it)
Download the zip file and leave it in your home folder.
Now got to your kernel source and go to arch/arm/boot and copy zImage
Paste your Zimage to the zip file and replace it.
Now we need the WI-FI modules otherwise your WI-FI will not be working
Go to the Kernel source code folder and go to driver/net/wireless/bcm4329_204 and copy bcm4329.ko
Got the zip file go to the System folder and replace it's bcm4329.ko with your bcm4329.ko
You are ready all you need to do is flash it.
Click to expand...
Click to collapse
will work with an ics device like amazon kindle fire?
Sent from my KFTT using xda app-developers app
HTCDreamOn said:
Thanks for the guide, but unfortunately I am getting errors during compilation:
Code:
make -j3 ARCH=arm
CHK include/linux/version.h
CHK include/generated/utsrelease.h
HOSTCC scripts/kallsyms
HOSTCC scripts/bin2c
CC scripts/mod/empty.o
arm-eabi-gcc: No such file or directory
Is your PATH set correctly?
make[2]: *** [scripts/mod/empty.o] Error 2
make[1]: *** [scripts/mod] Error 2
make[1]: *** Waiting for unfinished jobs....
make: *** [scripts] Error 2
I am trying to compile the Andromadus 3.0 kernel for HTC Vision, I'd really appreciate some help. I'm using Ubuntu 12.10 32 bit and the Android NDK.
Click to expand...
Click to collapse
Check your toolchain definition, looks like your path is wrong.
thewadegeek said:
Check your toolchain definition, looks like your path is wrong.
Click to expand...
Click to collapse
Thanks, you're right my path was wrong, but now I have fixed all the problems and it appears to compile successfully however there is no zImage in arch/arm/bin. Any suggestions? Thanks
HTCDreamOn said:
Thanks, you're right my path was wrong, but now I have fixed all the problems and it appears to compile successfully however there is no zImage in arch/arm/bin. Any suggestions? Thanks
Click to expand...
Click to collapse
Try building it again. Be sure to clean the source folder before you start
TheWizardOfROMs said:
Try building it again. Be sure to clean the source folder before you start
Click to expand...
Click to collapse
Thanks very much, I'd been recommended using Linaro tool chain instead and it works perfectly now, booting and WiFi and all. If I can learn some more advanced modding stuff to do to it then I'll release it in the Vision forums and I'll make sure to link to this guide
I installed Ubuntu on my windows laptop.my computer stars are 3Gigs of memory with 140 Gigs of available free space.Do I have enough space and is my laptop good enough to build kernels on.and I do use Ubuntu 12.04 to build kernels correct.I'm sorry I'm all new to this I just would like to be able to build a kernel for my sensation and HTC one which I will have next week.thanks very much for your time and expertise.
Sent from my HTC Sensation using xda app-developers app
rp56 said:
I installed Ubuntu on my windows laptop.my computer stars are 3Gigs of memory with 140 Gigs of available free space.Do I have enough space and is my laptop good enough to build kernels on.and I do use Ubuntu 12.04 to build kernels correct.I'm sorry I'm all new to this I just would like to be able to build a kernel for my sensation and HTC one which I will have next week.thanks very much for your time and expertise.
Sent from my HTC Sensation using xda app-developers app
Click to expand...
Click to collapse
I compiled with Ubuntu 12.10 and only 2 GB of RAM, and only 30GB free space. The tool chain and kernel really doesn't use up much room at all. As long as you don't go OTT on the -jx bit (I do -j3 as I've got a lowly core 2 duo) you should be fine. By the way if you get errors and you're path is definitely correct, then try with the Linaro tool chain instead.
got an error something like, "make ** [vm.virtual], waiting for unfinished jobs..." then stops, going to try new defconfig and new toolchain

Categories

Resources