Related
Dear all,
Did anyone succeed extracting kernel configuration from I9000XXJP3? Kernel version is 2.6.32.9, the vermagic is "2.6.32.9 mod_unload ARMv7"
extract-ikconfig doesn't work on it.
I succeeded extracting a zImage gzipped payload, but it seems not to contain any configuration in it (see attached).
/proc/config.gz doesn't exist, Samsung open source package (downloaded from Samsung open source site) contains only Android 2.1 Eclair or previous versions.
My target is to build tun.ko and, eventually, ext3/ext4 modules to make them working in Samsung Galaxy S I9000 with rooted I9000XXJP3.
Any idea?
Without froyo source code or a good Samsung Kernel (es. for himem capable) I think is impossible to play good with theses beta roms.
Ciao
Any news? I need tun.ko for jp3 too..
I have tried to compile the 2.6.32.9 kernel editing the .config in 2.6.9, the module tun.ko is accepted by the device, but I get a kernel panic!
redsh said:
I have tried to compile the 2.6.32.9 kernel editing the .config in 2.6.9, the module tun.ko is accepted by the device, but I get a kernel panic!
Click to expand...
Click to collapse
Did you use the stock linux kernel? Or the common from android.kernel.org?
I'm trying the same thing actually. Isn't there any default config for the processor that might work? I tried with the config from .29 but when loading the module it says wrong format.
try to build 2.6.32 with the 2.6.29 config ("yes" all missing stuff)
turn on your galaxy, adb push the tun.ko
try to load it, it will say "missing symbols" blabla
find the config options that match those symbols, enable them, recompile, try again
Great to see some people who are hacking the kernel! Keep it up!
But I'm afraid it is not going to be as easy as dropping aries_rev03_defconfig as .config in a 2.6.32 kernel tree and doing 'make oldconfig'. That's because many of Samsung's changes have not been included in the newer mainline kernel versions yet.
Samsung added quite a lot of low-level board support for their dev boards (and for the SGS, of course), did some customization and added a few drivers which you will need to forward-port to the newer kernel.
Please have a look at this thread, in which I've started a breakdown of the Samsung patches against Android Eclair's 2.6.29 kernel.
The best course of action I think is to git clone Android's kernel from AOSP, checkout the android-2.6.29 branch, apply Samsung's patches to that, then attempt to rebase your tree to a newer kernel version. (Note, you may want to start with small steps, to get a feel for what you're up against )
Note that there probably will be lots of merge conflicts which you need to resolve, and after dealing with all those, you also have to make sure that everything else that's merged still works as expected, but at least that will show you the amount of work involved. You will basically be doing all the work that Samsung is doing right now for their kernel for FroYo. It will be interesting to follow their progress on the mailing lists and on IRC.
bilboa1 said:
try to build 2.6.32 with the 2.6.29 config ("yes" all missing stuff)
turn on your galaxy, adb push the tun.ko
try to load it, it will say "missing symbols" blabla
find the config options that match those symbols, enable them, recompile, try again
Click to expand...
Click to collapse
Thats exactly what I did, but I got wrong module format... which is a fatal error. I need to invest further in the used config... maybe i did not pick up the right one properly..
miki4242 said:
Great to see some people who are hacking the kernel! Keep it up!
But I'm afraid it is not going to be as easy as dropping aries_rev03_defconfig as .config in a 2.6.32 kernel tree and doing 'make oldconfig'. That's because many of Samsung's changes have not been included in the newer mainline kernel versions yet.
Samsung added quite a lot of low-level board support for their dev boards (and for the SGS, of course), did some customization and added a few drivers which you will need to forward-port to the newer kernel.
Please have a look at this thread, in which I've started a breakdown of the Samsung patches against Android Eclair's 2.6.29 kernel.
The best course of action I think is to git clone Android's kernel from AOSP, checkout the android-2.6.29 branch, apply Samsung's patches to that, then attempt to rebase your tree to a newer kernel version. (Note, you may want to start with small steps, to get a feel for what you're up against )
Note that there probably will be lots of merge conflicts which you need to resolve, and after dealing with all those, you also have to make sure that everything else that's merged still works as expected, but at least that will show you the amount of work involved. You will basically be doing all the work that Samsung is doing right now for their kernel for FroYo. It will be interesting to follow their progress on the mailing lists and on IRC.
Click to expand...
Click to collapse
Yes that would be a lot of work. Maybe its better to just wait until they release the kernel from froyo. I read that they release their opensource stuff rather fast. But just for adding a module like ext4 I don't think you need those patches, because imho they didn't touch the fs of the kernel. We just need an adaquate kernel config and adding modules should be possible.
Phlogiston said:
Thats exactly what I did, but I got wrong module format... which is a fatal error. I need to invest further in the used config... maybe i did not pick up the right one properly..
Click to expand...
Click to collapse
Make sure you're using the same kernel version number and build number, because samsung kernels do not have the option to load incorrect module versions
Yes i've set the subversion as well but without the patches from samsung its impossible it seems. We need to wait and hope that they release the froyo kernel sources soon....
bilboa1 said:
Make sure you're using the same kernel version number and build number, because samsung kernels do not have the option to load incorrect module versions
Click to expand...
Click to collapse
Are you sure they set CONFIG_MODVERSIONS? It's off in the downloadable sources.
Just compare the output of `modinfo -F vermagic <yourmodule>` to `modinfo -F vermagic <modulewhichloads>` or to /proc/version .
did this get solved yet? I google'd for the tun.ko file for my i9000 using jp3 but nothing yet... if you have a proper one for the MoDaCo version here please attach it! ~
I think I saw someone's post with tun.ko for FroYo beta somewhere in these forums, I mean i9000 Android Dev. One of the guys here has found a way to compile kernel for jp* here. I am sure.
I actually found it attached somewhere in the forum and it was 1,5447 mb big I think it was... but it still didn't work for me so I presumed the kernel or something must have been wrong.
Hi guys!
I'm wondering what I'd have to do if I wanted to modify the built in apps inside Android..
I've got a HTC Hero running FroydVillain 1.5.0. Let's say... I want to modify the messaging app that's included, MMS.apk. I wouldn't know how to go about this, and I have a few questions...
Firstly, what sources exactly are used for building the built in apps for a given ROM? The source code link in the FroydVillain post, for example, is just for the kernel. The rest of the OS isn't there.
Secondly, I hear that in order to modify a built in app, you need to build the entire OS. If I just download all the code from Google official repo, and compile that, will it just... work on my phone, provided I use a kernel that is specific to my phone?
Lastly, are there any tips anyone has for someone who just wants to modify a couple of the built in apps? Is it possible to build them as standalone apps? Or import them into Eclipse?
I've had a search around the forum and the internets in general, and people have asked similear questions, but I've yet to find a good answer. This thread comes to mind: http://forum.xda-developers.com/showthread.php?t=635197
If anyone could help me, or point me in the direction of any help, that'd be awesome! Thanks!!
FunkTrooper said:
Hi guys!
I'm wondering what I'd have to do if I wanted to modify the built in apps inside Android..
I've got a HTC Hero running FroydVillain 1.5.0. Let's say... I want to modify the messaging app that's included, MMS.apk. I wouldn't know how to go about this, and I have a few questions...
Firstly, what sources exactly are used for building the built in apps for a given ROM? The source code link in the FroydVillain post, for example, is just for the kernel. The rest of the OS isn't there.
Secondly, I hear that in order to modify a built in app, you need to build the entire OS. If I just download all the code from Google official repo, and compile that, will it just... work on my phone, provided I use a kernel that is specific to my phone?
Lastly, are there any tips anyone has for someone who just wants to modify a couple of the built in apps? Is it possible to build them as standalone apps? Or import them into Eclipse?
I've had a search around the forum and the internets in general, and people have asked similear questions, but I've yet to find a good answer. This thread comes to mind: http://forum.xda-developers.com/showthread.php?t=635197
If anyone could help me, or point me in the direction of any help, that'd be awesome! Thanks!!
Click to expand...
Click to collapse
1) The whole sources for everything are there
http://github.com/ninpo
2) You can import the sources to eclipse, but I think you will need to build the entire tree, as opposed to just what you change
3) Apktool lets you do smali and resource edits on an APK. Without knowing what you aim to do, it's hard to guide you specifically.
Most apps are based on the sources provided by google. I assume you are talking about Froyo Hero ROMs (i.e. FroydVillain), which apps are generally built from the source of CyanogenMod. Specifically for FroydVillain, if you look around ninpo github you will see some packages with some changes to their code, although it does seem that many of the changes in recent releases are not there. I have actually PMed ninpo about this and hopefully this is only a technicality.... I assume that the other packages and apps (most of them) he just compiled off the CM sources without changes.
In any case, if you compile an app either from the CM source or from google's original sources, it should work just to copy the apk file - just make sure you use an appropriate ROM (i.e. Froyo ROM if you built it from Froyo sources). The reason to want the CM sources, is that if they have incorporated further fixes (over the google sources) you may want them.
Finally, some more practical advice: I would start with the google sources: http://source.android.com/source/index.html since I have found these instructions and explanations easier to begin with - it should be quite straight forward to build these sources on a linux machine (or VM).
Then you can also try to tackle the cyanogen source: http://wiki.cyanogenmod.com/index.php?title=Building_from_source currently missing instructions on how to build for hero. But if you only want to copy apks out of it, you can just build a generic build (like in the google souce).
If you have specific problems, ask and I'll try to help you.
Good luck.
pulser_g2 said:
1) The whole sources for everything are there
http://github.com/ninpo
Click to expand...
Click to collapse
For example where are all the changes to the dalvik code? I do not follow closely enough the changes in Froyd to point out other things which might be missing (if at all), but there are relatively few committed changes to the CM code. Specifically the dalvik code, ninpo mentioned hundreds of changes which caught my interest and are definitively not there.
The kernel sources do seem to be up to date always - been following that one closely .
Thanks for the advice I love this forum!
What I'm trying to do, in case you're wondering, ultimately, is to modify the built-in messaging application to give the user the option of sending a message by the normal method, or by using their provider's free webtext service, something that all the carriers seem to offer here in Ireland.
So, for example, you'd press the Send button, and you'd be able to select one of those methods. (of course, you'd have to have a data connection for the webtext). There's also be an interface for entering your login credentials for your carrier's website.
I'm doing this party because it would be very useful. I also feel that it would give me a good introduction to how you'd go about modifying Android. I mean, from a programming point of view, it shouldn't be *too* hard to do. I already have a simple standalone app that I made which can send a text message via an Irish carrier's webtext service. But it's all good experience to try to modify other people big codebases.
I have a good bit of experience with web application development, but my experience with other programming is a little more limited. I usually use PHP, where there's none of this compiling nonsense. You just write scripts and off they go!
So I'm gonna go off and see if I can set up an environment where I can build.. the OS, I guess.
If I was to take the vanilla official Google sources, would they work on my phone? Or would I have to use an official Google developer phone... or the emulator? Or maybe if I stopped writing here and investigated those links you've provided, I'd know that by know.
Brb, investigating
Yeh investigating and just trying to do it is usually the best way
To clarify what I was trying to say above: All the java code is obvious very portable - one of the big advantages of java. In the case of android it is compiled to an .apk file and this file should be, at the very least, portable to all android "devices" running this android version. So the apk you build (for example from the vanilla 2.2 sources) should work on the emulator (good for initial debugging) and any 2.2 ROMs.
erasmux said:
For example where are all the changes to the dalvik code? I do not follow closely enough the changes in Froyd to point out other things which might be missing (if at all), but there are relatively few committed changes to the CM code. Specifically the dalvik code, ninpo mentioned hundreds of changes which caught my interest and are definitively not there.
The kernel sources do seem to be up to date always - been following that one closely .
Click to expand...
Click to collapse
I'm currently on "vacation" from any and all Android development for a week. I'll be back after the weekend, at which time my modifications will be cleaned up and committed to git. The kernel is always current with my latest kernel release due to GPL obligations. The extra time away has also highlighted some changes I need to make both to the kernel and to my Android modifications when I get back.
Hacre said:
I'm currently on "vacation" from any and all Android development for a week. I'll be back after the weekend, at which time my modifications will be cleaned up and committed to git. The kernel is always current with my latest kernel release due to GPL obligations. The extra time away has also highlighted some changes I need to make both to the kernel and to my Android modifications when I get back.
Click to expand...
Click to collapse
Thanks Ninpo
Ok, so after having a million questions I thought I'd write up a quick little 'how to' with regards to porting.
And now the warning
Read and learn first, doing this could cause serious issues with your tab or even brick it. The tab is really tough, and hard to brick if you do everthing right but it could still happen. I'm not responsible if it does.
Where to start
Get good at reading, google searching and searching XDA. Lots of porting discussion regarding other phones can apply to the tab.
Learn to use Heimdell
Have a linux distro available, either by virtual box, or natively.
Technomancer where it all began
I've said it before and I'll say it again, without techs work miui wouldn't have been possible.
Reference technomancers thread here: http://forum.xda-developers.com/showthread.php?t=931857 on how to download the cm7 + sgt source, you're also going to want to follow the kernel making part, cause most likely you'll need to make adjustments to the init.rc which is inside the initramfs and requires building the kernel again.
porting x build
Get X build onto your computer and extract the update.zip for it.
Copy the boot.img into your linux environment and extract it using splitbootimg.pl script (note: Google it, plus this doesn't work with samsung builds). Compare the init.rc to your init.rc (from the sgt cm7 kernel source root folder). Specifically the most important part here is the PATH, LD_LIBRARY_PATH statement and BOOTCLASSPATH lines.
Build your kernel with the updated init.rc and flash with heimdell, it should still boot your cm7/miui build (if you were running it before) albeit with errors.
The system
Now following the awesome list of proprietary files (either from your source folder or technomancers github link) check the galaxytab-common-vendor-blobs.mk for the GT-P1000. It lists every file you need that's propreitary to the tab and where to put it.
Also you'll probably need the debuggerd from /system/bin on the cm7 build.
Compare the /system/build.prop of the cm7 build to your port, make sure the ril info is the same as well as the ro; model, brand, device, board, and platform lines.
Create an update.zip (or whatever you want to call it.zip) and try it.
It's not booting
Logcat is great, but I really suggest using the ddms from the android sdk tools. It's color coded, and gives a much nicer view of what's happening.
Using winmerge in windows or a linux file compare program start checking what other bin files may be missing that you require. Special notice to the xbin folder.
It works! I want to post it!
Ok, first up, make sure you have permission if this is someone elses custom build you've ported. Most people/groups are really good about it assuming you ask first and give them credit in your post.
Also credit everyone who helped, answered a question or sent you in the right direction. (it's just polite)
Second your going to want to make sure your update.zip flashes the kernel, read the update_script from the cm7 build to understand how it works.
So that's it for a start. roll up your sleves, gather your courage and get to it!
Please if you have other tips, add them to the thread, what's better 1 or 2 'developers/porters' or 100?
Thanks. This is very useful for me.
Thanks,
Following this method, with slight alterations to adjust, I was able to port an i9000 phone build to the tab in about 10 minutes, it's really not terribly that difficult once you have the right steps.
The first couple times are usually frustrating but after that you get the hang of it
Hi mssmison Thank you for your guide,it will be very useful in the future! I have only one request,how can I contact you? I have a proposal for you about a dev team (regarding an old think tank)
Thanks for the guide...
Is there any ROM left to port by the way?
Sent from my GT-P1000 using XDA Premium App
THIS THREAD IS FOR DEVELOPERS ONLY!
Please do not post your problems with ROM here.
Post your ideas about working on ICS or CM7 and your problems with compiling sources or similiar.
I posted my p350 sources on github:
https://github.com/pax0r
You will find an instruction how to download mine soruces and compile it by yourself at:
https://github.com/pax0r/android_device_lge_pecan
Here we can speak how to improve this ROM ( 7.2 ) and also how to work on ICS. On my github you can find branch "ics" - it is somehow releated to my work on ICS but it's not complete.
So let's make our device EPIC!
For the begining I will post my problems releated to working on P350:
The problem I have with 7.2 release is that BT is not working - drapalyuk fixed it somehow in last release but I don't know how. If any one have idea what was changed from 1910 to 2010 drap release please let me know!
Also I started to port .35 kernel for our phone - but it's not working yet. Kernel boots and console via adb is usable at this moment but Android itself does not start on it. I will post more in this topic later.
now syncing the source
hi pax0r,
I'm trying to build CM 7.2 using your guide and source code but I notice a couple of issue that maybe create problems to someone beginner like me:
1) if you run ./extract-files.sh on a phone with CM 7.2 (vivekkalady) the extraction will fail on 3 files: libloc-rpc.so, libloc.so, libcommondefs.so. Maybe they are located in a different path.
2) I think this line of code in extract-files.sh is wrong:
Code:
adb pull /system/lib/hw/gralloc.default.so ../../../vendor/$MANUFACTURER/$DEVICE/proprietary/lib/hw/gralloc.default.so
it should be:
Code:
adb pull /system/lib/hw/gralloc.default.so ../../../vendor/$MANUFACTURER/$DEVICE/proprietary/lib/hw/gralloc.pecan.so
to avoid issue later.
I'd like to try to compile ics. What do you think is missing to make it works?
Best Regards,
Gabriele
hi pax0r,
the market crash few times at the begin but after I reboot it seems to be fine.
I attached the logcat.
Gabriele
megasoft78 said:
hi pax0r,
I'm trying to build CM 7.2 using your guide and source code but I notice a couple of issue that maybe create problems to someone beginner like me:
1) if you run ./extract-files.sh on a phone with CM 7.2 (vivekkalady) the extraction will fail on 3 files: libloc-rpc.so, libloc.so, libcommondefs.so. Maybe they are located in a different path.
2) I think this line of code in extract-files.sh is wrong:
Code:
adb pull /system/lib/hw/gralloc.default.so ../../../vendor/$MANUFACTURER/$DEVICE/proprietary/lib/hw/gralloc.default.so
it should be:
Code:
adb pull /system/lib/hw/gralloc.default.so ../../../vendor/$MANUFACTURER/$DEVICE/proprietary/lib/hw/gralloc.pecan.so
to avoid issue later.
I'd like to try to compile ics. What do you think is missing to make it works?
Best Regards,
Gabriele
Click to expand...
Click to collapse
Thanks for your contribute
For me there are no missing libs - I was running it on 7.1 so mby Vivek 7.2 is missing them?
About gralloc - there should be two libraries gralloc.default.so and gralloc.pecan.so
About ICS I have no idea yet and now no time to look at it - studies, work and 7.2 rom is everything I can do at once ;P
pax0r said:
Thanks for your contribute
For me there are no missing libs - I was running it on 7.1 so mby Vivek 7.2 is missing them?
About gralloc - there should be two libraries gralloc.default.so and gralloc.pecan.so
About ICS I have no idea yet and now no time to look at it - studies, work and 7.2 rom is everything I can do at once ;P
Click to expand...
Click to collapse
I think the problem about missing libs is related with vivek 7.2 rom.
it's strange but I can't see gralloc.pecan.so. Anyway I'll check it this evening.
I was able to build everything using your tutorial but now I want to try with ICS. I need a bit of searching on internet.
Thank you for your work,
Gabriele
Hm I've checked it and it fact there were no gralloc.pecan in extract - it was obviously a bug, I pulled everything from device, then I was making some refactoring and I didnt check it after that. I will push commit with fixes today.
Thanks for pointing it!
I see a keylayout headset push, how did you make the headset button works? I replaced both keylayout (qwerty with the haptic fix and 7k), but the dammed button still with problems =/
Thanks
PD: The new implementation of gralloc will fix the dammn warning of prelink? (on the log)
I'm not sure if this keylayout will make headset work as I don't have one but it was suggested that it may help but this need test. New gralloc is because it is open source comparing to the original propriety one and I'm testing its speed - it is at least the same so I will leave it
To solve a problem with prelink there should be a prelink.map created but I dont know exatly how to build one. It is not a critical error but with prelink.map the boot process could be faster.
I still didnt fixed copybit ;/
If you have some idea how to help refer to this post:
http://forum.xda-developers.com/showpost.php?p=21592280&postcount=28
EDIT: copybit fixed
hey could some one with the headset use this app:
https://market.android.com/details?id=aws.apps.keyeventdisplay
click headset buttons few times and post output of this app (if any)?
BTW do the headset buttons works on Vivek ROM?
Let me compile it with the new changes and I will try
At least, I'm currently using 7.1.0 (your 7.1.0) and nothing happens. (EDITED)
call\music button problem
paxor can u rectify the call\music button for wired headset
Can you compile ICS with your new files and send it to me ??
I will try to port ICS with your new files
Hey pax0r, are you sure with the fix? Compiled, installed... but I get a weird screen on menu =S
Thanks
I get a minor success at porting .35 kernel for p350. It boots and works but it still to bugged to public release. However if you have any dev experience you can grab it here https://github.com/pax0r/lge-kernel-msm7x27 and help me fix it!
I don't know exactly how Android handles GUI, IDK how to help right now, but I just can told you about the bug when android it's displaying interface.
Can you upload your compiled ICS so that we can tweak it to get it working!
I've removed my built version and now my source code wont even build :/
Hi Pax0r! well, i want to become a dev, i have some kind of linux knowledgement and have a good willing to learn, could you please point me out to some basic tutorials about building from cyanogen source? i've searched myself in the wiki but i didnt saw anything about lg pecan, any information you can give me, I will study it and maybe then become of help in dev community! thanks in advance!!
There is not much info about anything for P350 as it is not very popular device. Everything you need to start building CM for P350 is here, in mine Readme file:
https://github.com/pax0r/android_device_lge_pecan/blob/gingerbread/README.mkdn
Everything else you need to get by yourself =p but I will try answer all your questions
I learned everything by checking avaibale info for similar devices (MSM7227 board, for example: LG P500, ZTE Blade) and source codes.
Hi !
I was searching for a new rom on my OP3 and i asked myself : But how did they do that ???. So I search for tutorial but I can't find anything except kitchen or obsolet tutorial. So, where can I Find a good way to learn ? The goal is to create my first custom rom.
Thanks
(Sorry if my english is bad, it's not my primary language)
Download "Brain.zip"
Elarmix said:
Hi !
I was searching for a new rom on my OP3 and i asked myself : But how did they do that ???. So I search for tutorial but I can't find anything except kitchen or obsolet tutorial. So, where can I Find a good way to learn ? The goal is to create my first custom rom.
Thanks
(Sorry if my english is bad, it's not my primary language)
Click to expand...
Click to collapse
Depending if you mean a stock based build or lineage, AOSP based etc. Stock based, you don't build, or compile. Mainly taking a clean stock build and tweaking it to what you want. A lineage based build is compiled by basically syncing source code, compile it and if you want you can cherry pick from other repos if you see extra functions, possible bug fixes etc. Most non stock builds are lineage based, compiled with some cherry picks.
There's a big difference between compiling a build a pulling others sources and actually developing. You can find numerous guides to get started with lineage, checking the wiki for whatever device they support will guide you.
You need a fairly modern CPU, recommended minimum of 8gb ram, SSD HD would speed it up, decently fast internet and when I compile I'll use Ubuntu as IMO it's easiest to get started with, tho I have compiled using ARCH as well, just took more fiddling.
https://forum.xda-developers.com/chef-central/android/guide-android-rom-development-t2814763
I think he mean how to coding etc
Gesendet von meinem ONEPLUS A3003 mit Tapatalk
Sidenote question, in the newer nougat builds how can you repack system.new.dat? The file_contexts is no longer a plain text file but a .bin and haven't found a workaround. Any tips?
Thanks
Hi ! And first, thanks to everyone
To be more precise in my question : If I want to make my own AOSP / LineageOS rom, I have to sync the source code and, if I want, tweak it then, compile and flash it ? Or there is another way ?
And, I don't have a good computer for that. It will be more slowly but is it alway possible ?
you can start by looking at http://wiki.lineageos.org/oneplus3_build.html for building LineageOS