Well hello everyone.
I am an application development student from Belgium.
I am proficient in Java, VB.NET, some c/c++ and also PHP/JS/HTML/CSS
Anyways, my recent interest has been going out to creating custom roms for the galaxy S!
The problem now is though, I was able to find some guides and such, but most were incomplete, and for HTC(and other) devices.
I have no idea what is different between making a ROM for galaxy S or a ROM for an HTC device.
If anyone would like to link me to some good resources that can help me on my way, or would like to collaborate (and in the meanwhile teach me a bit) I would be more than happy! (I am open for collaboration as I am pretty proficient in Java and I'm always happy to code and learn more about coding!)
I think the question is really want you want to do!
Custom ROMs for Android are as simple as using recovery console to replace files on the system with your own versions.
ie. Replace the framework.apk which contains all theme images with your own modified one, which you can use to skin the device. Same for replacing other system apps.
Unfortunately, most of these apps are closed source, so modifying them is difficult. The stock android system has open source versions of most of them though, and you can modify those and build them, and then replace the ones on the device. I'm not entirely sure how to build them up though, but it probably isn't too hard.
Then there are custom kernels, which let you actually change the underlying linux system underneath android - Samsung has an open source version of the kernel available that you can compile, and then flash to your phone using Odin or other tools. Compiling the kernel is pretty tricky though.
Well i'm really talking about stuff like SamSet, MoDaCo, Doc's ROM and others.
I'm not saying I want to create a pro ROM in a day or anything, but i'd really love to learn more to get better (always looking for more stuff to put on the resume, I guess?!)
Thanks a lot,
Kenny
Bump for some help
(sorry for the double post but i'm really eager to learn)
I don't have time to give a detailed response right now. However you will want to read up on yaffs (file system) and odexing/deodexing ROMs.
Thank you I will definately do that,
I am following a guide now to start out creating custom ROMs for android, however it was written for Motorola Droid and I have no idea what you have to do different for a samsung galaxy s.
I am a good coder, even though I say so myself, with a lot of experience. I also have a lot of linux experience, you name it
Only the problem is the old, and much known "where do I get started?"
So if anyone can point me out in the right direction on that, tell me how/where you started out, I would appreciate it greatly!
Thanks!
Very sorry to bump again
I set up my environment in ubuntu today to get started (just gotta fix a few errors, didn't know android wouldn't compile on java 1.6, only on 1.5)
Anyways, still need some help here! thanks!
Again I am awefully sorry for the bump here but i'd really like some help.
Note that i'm not a newbie at coding whatsoever and i'm not unfamiliar with some hardcore java, c/c++ and other languages, I'm just having trouble getting started when it comes to modding an existing android release (there are tutorials on HTC and other devices but some methods do not apply to the galaxy S)
If you're trying to create a ROM from scratch then unfortunately you're out of luck at the moment. No one has really managed to do so yet. By "from scratch" I mean the Android Open Source Project (i.e. official Android git repository).
What you can do is grab an existing firmware. Extract the contents, de-odex the apks, modify them or add new apks, optionally you can also compile a custom SGS kernel using Samsung's kernel source. Then you can re-odex the ROM, pack it back up and distribute it.
There's no real "starting place" as such and you won't yet find any tutorials about how to create SGS ROMs. Just give it a go and see where you get.
Yes, I do mean creating a ROM from stock samsung firmware, of course.
So my next logical question would be now:
How do I go over extracting contents from the existing samsung firmware, de-odexing and so on?
Any links/guides/tips are greatly appreciated, as long as they are applicable to this cell phone and not totally crap, thanks!
Samsung uses rfs, I think you should know. There is a thread somewhere in this forum regarding extracting .rfs file. Understood you need Debian though.
For some readup, go search for a famous guy named JesusFreke. Tons of materials...
Hope that from here onwards, this can lead you on, and to find out more. Google is your friend too...
I'm afraid my biggest problems already occur in setting up the environment, so it's really the very beginning that gets me stuck, i'm sure coding would be a bikeride compared to setting up the environment for me (i'm no hero in linux,not at all, i'm afraid)
How the hell do I get from point A (being downloading the full source) to point B (starting to create a custom ROM?)
thanks
of course if anyone has the time, and wants to, you can PM me your msn or something, if anyone is up to it
Raykoid666 said:
I'm afraid my biggest problems already occur in setting up the environment, so it's really the very beginning that gets me stuck, i'm sure coding would be a bikeride compared to setting up the environment for me (i'm no hero in linux,not at all, i'm afraid)
How the hell do I get from point A (being downloading the full source) to point B (starting to create a custom ROM?)
thanks
of course if anyone has the time, and wants to, you can PM me your msn or something, if anyone is up to it
Click to expand...
Click to collapse
Agreed completely! Getting a full cross-compilation to Samsung's Android going is seriously difficult! There have been some promises for tutorials and guides for setting things up though, but none have appeared yet. Probably because it's hard!
Well thank you for agreeing with me on that.
I am really hoping for anyone that can help me out here, either on here or in private, and give some detailed instructions on how to get started.
Hell there is enough information on creating roms alread, deodexing, adding/removing apps etc etc etc... The real problem lies in setting everything up properly.
I think I have gotten to the point where I'm compiling the android source (without samsung specific files)
note i'm saying "i think i am compiling" because i'm hoping it won't error out on me again after an hour of compiling!
But once that is done... I have no idea where to go next, where to get the samsung specific files, or what to do with them whatsoever once i have them
thanks!
Android generic source won't actually help you much. Samsung has made a huge number of changes to it, and while it is all open source, backporting their changes to get your stock source running on the phone is a major undertaking. I believe cyanogenmod was actually working on this, but it seems without much success so far.
What the other rom makers you see are doing is taking a snapshot of a running rom, copying over all of the APKs and the files on a running device, and then tweaking those. ie. Opening up framework-res.apk and changing the image files inside.
The update.zip roms that are what most people are doing are really just using the Android recovery to replace files on the phone with their own versions. Since the underlying system is linux, and everything is a file, this actually works pretty well.
The kernel development effort is completely separate from the rest of the system though, and Samsung has provided the entire source tree that just has to be compiled. I'm a bit stumped myself on all the details of setting it up, but I have seen some threads on this forum about it, and it didn't seem too bad to set up. Apparently you shouldn't use the codesourcery toolchain though, or something. Not too clued up on it, sorry. Hopefully someone with the details can chime in, or give us a link to the old post on it (I'm failing to find it using the search function! )
Alright sounds good!
So these recovery files you are talking about (the contents of /system) how do i retrieve those from a base ROM such as JM7 or the likes after a clean flash?)
Raykoid666 said:
Alright sounds good!
So these recovery files you are talking about (the contents of /system) how do i retrieve those from a base ROM such as JM7 or the likes after a clean flash?)
Click to expand...
Click to collapse
Root your phone, zip them up onto the sdcard, and then copy them off.
There are probably better methods, but this works fine.
Also, with credits to Unhelpful, he has told me that the correct toolchain to be using is 'uClibc or eglibc toolchain with ct-ng'. I have no idea what to do with that yet, but it's a start.
RyanZA said:
Root your phone, zip them up onto the sdcard, and then copy them off.
There are probably better methods, but this works fine.
Also, with credits to Unhelpful, he has told me that the correct toolchain to be using is 'uClibc or eglibc toolchain with ct-ng'. I have no idea what to do with that yet, but it's a start.
Click to expand...
Click to collapse
You don't even need to root your phone to pull /system Ryan
adb pull /system <random folder>
is all you need ^^
Alright thank you, I managed to get all the /system files using abd pull /system
now next thing up would be de-odexing right, before I go editing stuff?
Now before I go de-odexing. Can anyone tell me what exactly de-odexing is and why I need it?
and what do I need to do to create an update.zip again?
thanks a lot all!
Tayutama said:
You don't even need to root your phone to pull /system Ryan
adb pull /system <random folder>
is all you need ^^
Click to expand...
Click to collapse
Haha cool, didn't know you could pull whole folders!
Raykoid666 said:
Alright thank you, I managed to get all the /system files using abd pull /system
now next thing up would be de-odexing right, before I go editing stuff?
Now before I go de-odexing. Can anyone tell me what exactly de-odexing is and why I need it?
and what do I need to do to create an update.zip again?
thanks a lot all!
Click to expand...
Click to collapse
The apk files in Android are odexed - that means they have a special index applied for dalvik that speeds them up somehow! I don't know how, I haven't checked how it actually works.
The important point is though:
odexed is faster, but you can't edit it because of signatures or something technical
deodexed means you can change it however you want
More useful info can be found from google - lots of it!
update.zip is easy - it's a zip file in a special format that can be understood by Android's recovery console. The easiest way to do it is to grab an existing update.zip and modify it as needed. Tayutama has millions of em around, so use his!
Then you need to sign it once you're finished with it so that the SGS will accept it. Samsung made a boo-boo and didn't disable the test keys for the 2.1 SGS firmwares. That makes it easy!
http://www.londatiga.net/it/how-to-sign-apk-zip-files/
Just use the test keys to sign it, and then copy it to /sdcard/update.zip and reboot into recovery and it'll work.
Hi All,
I saw some references to the redbend_ua tool used here.
Can someone explain to me what is this used for and where can I find it in my Fascinate device - I mean is it part of the software I should have already or do I need to install it?
Thanks
Joe
Its used to flash recovery partition in fascinate and its there in Recovery Flashing Threads, dont try if you dont know what it means, its dangerous
But is it pre-insalled in Samsung Fascinate for Verizon?
Can you guide me where is it located on an original device?
Samsung does not supply it to the public. Its one of those "leaked" things.
It is packaged with certain roms where it is used to flash things. Ok, intentionally cryptic. If you are savvy, you could unpack it from the zip file, and read the install scripts that use it to get a basic idea of syntax. If not, probably better left alone.
Use Odin or Heimdall instead - you can get into adequate trouble with those too
Finally went and made the beginnings of a general flashing guide that should eventually cover the basics of everything streak related.
forum.xda-developers.com/wiki/index.php?title=Dell_Streak/Flashing_Guide
For the time being I ask that noone directly adds to the list and instead gives me the details to add myself. As it's a wiki I cannot force anyone to do this but i WILL edit it to match the phrasing or possibly remove it if it's redundant.
It is intentionally not excessively verbose/detailed as too much additional detail is only needed if you're completely new to flashing/messing with software.
It doesnt handhold your way though flashing stuff, if you dont know how to use the command line you should NOT be flashing roms as when you brick you only have your self to blame for not having the needed prereq ability pc wise.
It also only covers windows as I only work/dev on windows, if anyone on *nix/osx wants to give me the OS specific details i'll go ahead and add it
It's also missing most of the details on how to use QDL tool as i've never used it or needed it. I need someone to add/help me add the details in the same guide style without handholding users though using it
It's also very generic as installing most roms dont have specific requirements to them (excluding setting up SD's install.txt which is it's own thing)
it does NOT and will not cover using automated tools such as Gingerbreak or mutlirecovery flasher as automated tools ultimately mean that you do not wish to read the instructions on how to do it properly. (on the streak at least) (no offense to respective makers)
edit: it should also NEVER contain links to the forum and especially "read this post to do xxx" stuff, it should be more or less self contained except with regards to downloading files, which should either be direct links (preferably not on a filesharing site like multishare/etc) or links to another section of the wiki containing links
I know there's a couple users about with compiled guides but I cant recall who/which offhand as I dont need them myself. I'd like your input whoever you are
Great job!
Sent from my Inspire 4g using XDA Premium App
I have added some comments on the talk/discussion page on the wiki. If there is any specific topic you need help on in the wiki let me know.
TheManii said:
Finally went and made the beginnings of a general flashing guide that should eventually cover the basics of everything streak related.
forum.xda-developers.com/wiki/index.php?title=Dell_Streak/Flashing_Guide
For the time being I ask that noone directly adds to the list and instead gives me the details to add myself. As it's a wiki I cannot force anyone to do this but i WILL edit it to match the phrasing or possibly remove it if it's redundant.
It is intentionally not excessively verbose/detailed as too much additional detail is only needed if you're completely new to flashing/messing with software.
It doesnt handhold your way though flashing stuff, if you dont know how to use the command line you should NOT be flashing roms as when you brick you only have your self to blame for not having the needed prereq ability pc wise.
It also only covers windows as I only work/dev on windows, if anyone on *nix/osx wants to give me the OS specific details i'll go ahead and add it
It's also missing most of the details on how to use QDL tool as i've never used it or needed it. I need someone to add/help me add the details in the same guide style without handholding users though using it
It's also very generic as installing most roms dont have specific requirements to them (excluding setting up SD's install.txt which is it's own thing)
it does NOT and will not cover using automated tools such as Gingerbreak or mutlirecovery flasher as automated tools ultimately mean that you do not wish to read the instructions on how to do it properly. (on the streak at least) (no offense to respective makers)
edit: it should also NEVER contain links to the forum and especially "read this post to do xxx" stuff, it should be more or less self contained except with regards to downloading files, which should either be direct links (preferably not on a filesharing site like multishare/etc) or links to another section of the wiki containing links
I know there's a couple users about with compiled guides but I cant recall who/which offhand as I dont need them myself. I'd like your input whoever you are
Click to expand...
Click to collapse
Thanx!
hy,
could someone please explain to me how many partitions the s4 has, why is it so hard to repartition the internal memory?
is all memory located on one chip and how is the partitioning handled, the partitioning information is surely not stored with the OS, so where is it?
where is the bootloader stored then and why is it so hard to unlock it, its just a piece of memory just like the OS right?, is it coded on a separate chip that cannot be rewritten? or hidden somewhere encrypted within some other process?
please guys some clarification here this cant be so hard!
re: partitions & bootloaders
adrovic.ad said:
hy,
could someone please explain to me how many partitions the s4 has, why is it so hard to repartition the internal memory?
is all memory located on one chip and how is the partitioning handled, the partitioning information is surely not stored with the OS, so where is it?
where is the bootloader stored then and why is it so hard to unlock it, its just a piece of memory just like the OS right?, is it coded on a separate chip that cannot be rewritten? or hidden somewhere encrypted within some other process?
please guys some clarification here this cant be so hard!
Click to expand...
Click to collapse
The partition table is stored in the PIT file (partition information table).
The reason it's so difficult to unlock bootloaders is that samsung and all the other cell phone
companies always try to make it as difficult as possible to do because the cell phone companies
frown upon people like the developers here who usually do succeed in unlocking the bootloaders.
It's getting more and more difficult for the developers to do with most cell phones now-a-days.
They don't like developers or end users messing around with the phones firmware or the bootloader.
Even the slightest modification of the PIT file will cause the phone to fail in
in such a way that only repair shops that has a JTAG burner can repair it. (expensive)
That's why NONE of the custom roms found here in XDA contain any PIT files.
If they did then during the flashing procedure it would over-write the stock one. (bad)
It's similar to the Windows MBR (master boot record) which if even slightly off
Windows will not boot.
In Windows a corrupt or missing MBR is a very easy thing to fix so its not a problem.
If the internal memory was repartitioned differently than stock default the phone would
become a shiny brick which would not even be flash-able with stock or any of the custom
roms or firmwares if the partition table is setup even slightly wrong.
Good luck, I would advise you to try to have more interest in becoming a developer of custom
roms here in xda rather than having so much interest in bootloaders and partition tables. LOL
Misterjunky said:
The partition table is stored in the PIT file (partition information table).
The reason it's so difficult to unlock bootloaders is that samsung and all the other cell phone
companies always try to make it as difficult as possible to do because the cell phone companies
frown upon people like the developers here who usually do succeed in unlocking the bootloaders.
It's getting more and more difficult for the developers to do with most cell phones now-a-days.
They don't like developers or end users messing around with the phones firmware or the bootloader.
Even the slightest modification of the PIT file will cause the phone to fail in
in such a way that only repair shops that has a JTAG burner can repair it. (expensive)
That's why NONE of the custom roms found here in XDA contain any PIT files.
If they did then during the flashing procedure it would over-write the stock one. (bad)
It's similar to the Windows MBR (master boot record) which if even slightly off
Windows will not boot.
In Windows a corrupt or missing MBR is a very easy thing to fix so its not a problem.
If the internal memory was repartitioned differently than stock default the phone would
become a shiny brick which would not even be flash-able with stock or any of the custom
roms or firmwares if the partition table is setup even slightly wrong.
Good luck, I would advise you to try to have more interest in becoming a developer of custom
roms here in xda rather than having so much interest in bootloaders and partition tables. LOL
Click to expand...
Click to collapse
thanks for the answer, but the question is how can this be so sensitive.
lets say for example one would take the pit file from the s4 google edition and put it on the samsung s4.
these 2 phones have identical hardware!
as you say the pit file is part of the FW and is just not being touched during the flashing process, but the pit file is being read out by some other peace of software, so basically that peace of software is the only thing that can verify the pit file, so if you also change that piece of software than everything should work just perfectly.
Misterjunky said:
It's similar to the Windows MBR (master boot record) which if even slightly off
Windows will not boot.
Click to expand...
Click to collapse
MBR and bootloader in the PC world, are two completely different things....
@adrovic.ad: Too many. List of Samsung S4 partitions
Partition information and the bootloader are both at a lower level than the OS, so neither would be stored with the OS. Both would be located in low level storage, which cannot be written without tools and software that cannot be discussed here. The bootloader transfers control of the hardware from the low level firmware to Android, and then sits quiet. As to why it's so difficult to unlock a bootloader, it isn't so long as you don't have a US S4 such as the SGH-I337. In that one, AT&T encrypts the bootloader to prevent modifications to the device. To break the encryption would require more time than the current age of the Universe.
Most Galaxy S4 devices don't have a locked bootloader.
It's harder than you think. It's probably much harder than I think, and I think it's hard.
Hello everyone,
Please, just a question about repartitioning a PIT file via Odin. I´m a bit confused about information I have read about the result of the repartitioning operation.
In some forums appear to say the repartitioning operation via Odin is, first, a values rewriting of GPT entries, and after that any kind of formatting/wipe of all partitions.
In other words, if i repartition a PIT file exactly with the same values I have in my GPT table, does nothing occurs and the content of partitions keeps, or partitions data are lost?
Sorry about my english, and thank you for any answer you can give me.
D,
hi,
if i understand correctly, you would still be performing a repartition operation , which will destroy data during the process.
Although, if you have some experience with data/forensic recovery and can get the tools ported to your tab, it's likely
you may be able to recover a fair amount of what you lose without the data being corrupted.
That being said your repartitioning would need to succeed first.
The better approach for rescuing your data would be to pull the mmcblocks/partitions off of the device and onto
your pc [Linux] as img files through ADB [android debug bridge], BEFORE YOU PERFORM THE OPERATION.
That way if you fail in repartitioning [ which is highly likely]
your data will still be preserved on your pc. To be able to pull the information/data from the device, the device must be rooted
or have a custom recovery available with properly functioning access to/through adb for root functions and adb shell as root.
questions belong in q&a by the way.
m
hi,
if i understand correctly, you would still be performing a repartition operation , which will destroy data during the process.
Click to expand...
Click to collapse
Thank you for you answer. Well, what i´m trying to do is just an "experiment" resizing partitions. Of course there are other ways to do it, but what i´m thinking about is this:
Imagine the recovery partition was located in the first memory addresses, so, in one of the first GPT entries, and what i want to do is just modifiy size of last three partitions, so, three last entries in GPT table. If i create a new PIT file exactly with the same values that i have in the GPT table of the device but only modified values for the three last GPT entries, after perform a repartitioning via Odin and restart the device the recovery will be still there?
So, that is the sense of my question: Repartitioning does only write the values in the GPT table, or besides performs any kind of data lose in partitions (wipe,formatting...) ?
questions belong in q&a by the way.
m
Click to expand...
Click to collapse
Sorry and thank you, next time i´ll pay attention to it.
On older devices I had some success resizing partitions using parted in recovery mode via adb.
parted doesn't support ext4 as far as it's useful functions goes, you would have to create/resize any partition
as ext2 and reformat from there, cute approach but more hassle/trouble than it's worth.
for your experiment, be sure you can afford a new tab ! :silly:
i'm pretty sure your block layout is hardcoded in the bootloader. So you will probably end up creating
a very fashionable serving tray.
Meaning your device won't be able to find recovery partition, also there is likely a set amount of partitions allowed
by way of kernel if i remember correctly.
If your trying to get rid of that annoying no-execute permission in data thing, getting rid of FUSE would maybe get that done.
m
Thanks again for your answer. Experiment cancelled, currently no budget for a new tab.
Just a last -and sure a stupid- question, please: In your opinion, what would happen if i extract the PIT file from my device, and use itself to repartitioning via Odin? I mean, just specifying the PIT file and marking Re-Partition, other options (PDA,Phone,etc) unmarked? After restart, could work the tablet or I´ll get a brick?
Thanks again.
Regards.
D,
hi,
That's not a stupid question at all. I would suggest you read this thread all the way through
http://forum.xda-developers.com/tab-4/help/t530nu-pit-file-t2968498
also search via your preferred engine and XDA for terms/variations
samsung pit file signed odin heimdall
so far, the chances of repairing/modifying partition table on these newer devices [samsung] is slim/grim.
However maybe utilizing external/usb-otg storages to suit your needs would be a way to go. :good:
m