[Q]Modifying Cyanogen: "vendor" overlay or fork? - Hero, G2 Touch General

Hi all,
I've been theming a little but figured it'd be better to compile from source (something to do with custom layout xmls). I'm quite new to ROM compiling so I have a question for the ROM builder here: what is the way to go for modifying/adepting CM?
I can "fork" it and use the structure and build files from the original and just replacing/editing the files in those directories. But a more elegant way would be to add the modifications in a seperate vendor overlay and use that instead (with the DEVICE/PRODUCT_PACKAGE_OVERLAYS). That way I can keep the original files and keep the modifications in a seperate directory. I've been experimenting with that a little, but with no succes so far. So I'm not even sure it can be done.
Thoughts, opinions?

krispijn_s said:
Hi all,
I've been theming a little but figured it'd be better to compile from source (something to do with custom layout xmls). I'm quite new to ROM compiling so I have a question for the ROM builder here: what is the way to go for modifying/adepting CM?
I can "fork" it and use the structure and build files from the original and just replacing/editing the files in those directories. But a more elegant way would be to add the modifications in a seperate vendor overlay and use that instead (with the DEVICE/PRODUCT_PACKAGE_OVERLAYS). That way I can keep the original files and keep the modifications in a seperate directory. I've been experimenting with that a little, but with no succes so far. So I'm not even sure it can be done.
Thoughts, opinions?
Click to expand...
Click to collapse
The way I did it on Floyo is the following:
I forked the android_vendor_cyanogen repository, and then add this line to the products/common.mk:
Code:
# Common CM overlay
[B]+#PRODUCT_PACKAGE_OVERLAYS += vendor/cyanogen/overlay/floyo[/B]
PRODUCT_PACKAGE_OVERLAYS += vendor/cyanogen/overlay/common
Then all my floyo specific theming goes under overlay/floyo in the same repository. You can see my initial commit for this here - unfortunately its not just theming stuff there....
To build the CM untouched theme for floyo, I (almost) only comment the above line and rebuild. In my case, I have also changed some default colors in the code itself, under the framework/base package and the CMParts package. To build the CM theme I undo these changes as well and then rebuild.
One final note, if your building just one ROM with one theme, you should not have any problems with this. If your thinking of using this to build the framework-res.apk only, and possibly other files your theming, and then pushing only them to a CM6 based ROM, from my experience you'll run into all kinds of sh**.
The way I make the CM theme today, is I do the above changes (comment the above line and undo my default colors code in the code of the framework and CMParts). Then do a completely clean build (remove the entire out directory first). Finally I do a full recursive diff of the entire ROM against the entire regular floyo ROM and package only those files which changed under system/framework/ and system/app/. Basically, I am releasing 2 different ROMs, just to save bandwidth I only package the diffs.
Hope this helps.

Exactly what I wanted to know.. thanks man!

krispijn_s said:
Hi all,
I've been theming a little but figured it'd be better to compile from source (something to do with custom layout xmls). I'm quite new to ROM compiling so I have a question for the ROM builder here: what is the way to go for modifying/adepting CM?
I can "fork" it and use the structure and build files from the original and just replacing/editing the files in those directories. But a more elegant way would be to add the modifications in a seperate vendor overlay and use that instead (with the DEVICE/PRODUCT_PACKAGE_OVERLAYS). That way I can keep the original files and keep the modifications in a seperate directory. I've been experimenting with that a little, but with no succes so far. So I'm not even sure it can be done.
Thoughts, opinions?
Click to expand...
Click to collapse
If you want just to change xmls - i think apktool is more simple way to do this .

hawst said:
If you want just to change xmls - i think apktool is more simple way to do this .
Click to expand...
Click to collapse
True, but I want to do more than that eventually... also compiling is fun and it gives me a better understanding of Android

Related

Build OS????

My friend has the Mogul and on PPCgeeks.com he installed buildos which is a totally customizable rom that allows you to choose what you want on it upon installation. I and many others I'm sure would love to have something similar. Any info on this would be great!!!!
Future thanks!!!!!!1
that's what runs inside of the simple wm6.1 kitchen I posted. All you need to do is change OS files (SYS Folder and XIP) from my old clean developer edition to newer and more stable ones made by -MyHTC-, Erofich, etc.
I also recommend learning about UC (User Customization) 2.0. Search for it on xda. Really useful for on-the-fly type customization, but the ROM image needs to be compatible.
Still trying to find some time to develop my WPF kitchen...thinking about multi-device support...
ND4SPD said:
that's what runs inside of the simple wm6.1 kitchen I posted. All you need to do is change OS files (SYS Folder and XIP) from my old clean developer edition to newer and more stable ones made by -MyHTC-, Erofich, etc.
I also recommend learning about UC (User Customization) 2.0. Search for it on xda. Really useful for on-the-fly type customization, but the ROM image needs to be compatible.
Still trying to find some time to develop my WPF kitchen...thinking about multi-device support...
Click to expand...
Click to collapse
So forgive me for my ignorance, but if I'm already running on My-HTC rom will your kitchen work. And I did notice the kitchen before, but I took a look at it and felt I was getting in a little over my head. I have flashed my phone a few times and tweeked it out a lil, but by all means, I am still fairly new here. So I'm gonna do some homework myself based on ur feedback, but thanks again and we all look forward to seeing more of your work

[IDEA] Multidevice kitchen

I've been thinking lately... I've been thinking of creating a new multidevice kitchen. The kitchen would support every current device, be based on the newest version of Bepe's kitchen or maybe the visual kitchen. It would add certain things like:
Automatically insert the cecompr.dll needed for both LZX and XPR compressions
Automatically hex edit the imgfs.bin during the cooking process to allow to LZX compression
It would come with an empty payload file for every device
It would support multiple languages and come with language packs
It would use the standard layout of bepe's kitchen/the visual kitchen so it would be easy to also keep build packages that would apply to every kitchen.
If I could get enough cooks involved from other devices, we could even have base STRIPED OEMs from every device that people can easily download.
We can make it automatically be able to dump any ROM and easily extract its XIP or SYS and import them into the kitchen or make the files into a package compatible with the kitchen that people could upload for everyone else to use. (Easier to spread new builds leaked by other people.)
I need more ideas as to what we could make this kitchen do.
I also need to know if any cooks would be willing to help out as it would be a MASSIVE project.
I would start it as soon as I'm done with two ROMs that I'm currently working for and a few kitchen that I'm modding for some people for LZX/XPR multicompression.
No comments, yet.
I'm working with ervius to add the LZX compression to the kitchen itself.
If no one helps, then it's going to be a little hard to do since I will have to download the default ROM for each and every device and then strip down the OEM. Then create bigROM packages to release as well. And then I can't test it since I don't have every device, so it's going to be a little bit of a slow process.
What I will end up doing will be more like just taking ervius kitchen, add a few things here and there and make all the packages and builds and whatnot available. Or at the least create a thread where people can post packages left and right. A repository of sorts. (A lot like the PPCgeeks's BuildOS but compatible with every device and using ervius awesome kitchen.)
Sounds like what Anchilus had one time! I think it was named as hypercore. But great idea though. I am not an expert cook or programmer, but I do cook ROM for myself sometime. My biggest thing is porting the ROM, doesnt matter what tutorial I read, I just dont get it LOL
Take a look in the raphael forums. Already done.
Will Help You
Ivan,
You know that I am willing to do anything I can to help you. Problem is that we have the same devices and you are my mentor so I am not sure how much help I would be, but whatever you need, you name it and I will do my best to help you out however I can.
GSLEON3 said:
Take a look in the raphael forums. Already done.
Click to expand...
Click to collapse
I looked. I couldn't find a multidevice kitchen...
GSLEON3 said:
Take a look in the raphael forums. Already done.
Click to expand...
Click to collapse
I think you mean this? http://forum.xda-developers.com/showthread.php?t=505800
Would be a great idea one kitchen for all devices, although I think the extra devices should be added in the form of plug-in, because nobody likes to dl a 20 GB kitchen . I would help but I'm not that great at dumping but especially not with the still changing structure of ervius visual bepe's kitchen. Is there a wiki or tutorial somewhere that properly explains where to put which folders? 12
Yes, it wouldn't include all the devices at once. The aim of the project is to provide plugin packages for every device. A standard repository of oem packages (divided by QVGA, VGA, WVGA, etc), a standard repository of SYS and XIP builds, and a standard set of stripped down OEMs from different devices. Everything would be downloaded seperately. It's a huge project, that's why I would need lots of help.
EDIT: Just read that link. Kind of like that, but for multiple devices. Including language packs and all.
ivanmmj said:
Yes, it wouldn't include all the devices at once. The aim of the project is to provide plugin packages for every device. A standard repository of oem packages (divided by QVGA, VGA, WVGA, etc), a standard repository of SYS and XIP builds, and a standard set of stripped down OEMs from different devices. Everything would be downloaded seperately. It's a huge project, that's why I would need lots of help.
EDIT: Just read that link. Kind of like that, but for multiple devices. Including language packs and all.
Click to expand...
Click to collapse
To get the attention of the cooks I think you should start sending email to the chefs and maybe a couple of mods too. I don't think it should be much of a problem on the raph forum, we are blessed with kind and sharing chefs, 12
i would love to help out with the kitchen.
although, i dont like bepe's way of cooking as much as the old way
multi-device sounds great, like in the days of hypercore
mbarvian said:
i would love to help out with the kitchen.
although, i dont like bepe's way of cooking as much as the old way
multi-device sounds great, like in the days of hypercore
Click to expand...
Click to collapse
You can use my kitchen (based on visual kitchen) to add more devices but someone should develop a kind of frontend app to have ability to download only desired build, device OEMs, VGA/QVGA etc (manual selection will be a nightmare for normal users) . I can help in building such a kitchen but I can't write app, sorry
ivanmmj said:
Yes, it wouldn't include all the devices at once. The aim of the project is to provide plugin packages for every device. A standard repository of oem packages (divided by QVGA, VGA, WVGA, etc), a standard repository of SYS and XIP builds, and a standard set of stripped down OEMs from different devices. Everything would be downloaded seperately. It's a huge project, that's why I would need lots of help.
EDIT: Just read that link. Kind of like that, but for multiple devices. Including language packs and all.
Click to expand...
Click to collapse
qsqa said:
You can use my kitchen (based on visual kitchen) to add more devices but someone should develop a kind of frontend app to have ability to download only desired build, device OEMs, VGA/QVGA etc (manual selection will be a nightmare for normal users) . I can help in building such a kitchen but I can't write app, sorry
Click to expand...
Click to collapse
You mean like an kitchen appstore or a bat to move everything into the right folders? 12
That's a great idea. An app that automatically downloads the needed files just for your device type of thing... I'm not a programmer, though.
I want this to also have language packs that modify the language of the ROM.
Let this be the kitchen to rule all kitchens.
ivanmmj said:
That's a great idea. An app that automatically downloads the needed files just for your device type of thing... I'm not a programmer, though.
I want this to also have language packs that modify the language of the ROM.
Let this be the kitchen to rule all kitchens.
Click to expand...
Click to collapse
i agree, this would be a very great idea. I think ppcgeeks has something similar with their BuildOS kitchen
p.s. ivan, while you're here, could you answer this question for me?
ivanmmj said:
Replace the FIRST one and FIRST ONE ONLY with "LZX". Save the file, close the hex editor. Let your kitchen do it's thing.
That's it.
http://www.4shared.com/file/101370353/b7650aff/Compression.html
Click to expand...
Click to collapse
do we need to do this step on the "mythical" cecompr.dll?
thanks
mbarvian said:
i agree, this would be a very great idea. I think ppcgeeks has something similar with their BuildOS kitchen
p.s. ivan, while you're here, could you answer this question for me?
do we need to do this step on the "mythical" cecompr.dll?
thanks
Click to expand...
Click to collapse
Already answered there.
But,
Yes.
The cecompr.dll is what tells the XIP how to read the LZX compressed imgfs.bin. The hex editing is what tells the kitchen tools to write the imgfs.bin in LZX compression.
I worked with evirus and now his kitchen has an option for LZX compression. It will do everything automatically. ^_^
That's a great idea. Not sure it could work on my device (ks20) as bepe's kitchen crashes on my nk.exe so I have to build xip part the old way (using xipport). Anyways, if you need french 96dpi resources, I can give you mine.
And for this project, instead of a special software to download packages, why not using a svn repository ?
Although a SVN repository would be awesome, I wonder if there would be a legal problem just like there was with the XDA FTP server used to host ROMs and stuff for building ROMs?
Yes, that's possible... perhaps we should ask a moderator, what was the exact reason it was removed (because after all, everything is still present on this forum, it's just not grouped in 1 place, but I think legal issues remain).
I also know that somewhere on the web, there is a svn server for winmo builds (I had once a wm build that had .svn folders).
Ivan, You can use my site to host your files, repositories, and current roms. I can alot you as much space as needed and even a .info domain name if you like. It will be hosted on the the same host as mycw.info (My gf's site for our chickens and stuff.) PM me or just respond on this post.
DestructDez1 said:
Ivan, You can use my site to host your files, repositories, and current roms. I can alot you as much space as needed and even a .info domain name if you like. It will be hosted on the the same host as mycw.info (My gf's site for our chickens and stuff.) PM me or just respond on this post.
Click to expand...
Click to collapse
PM sent. Thank you!!

Making ROMs

So this is combination question/idea.
I have been reading around and it seems to me that most ROMs are made mostly just by taking existing ROMs (often taking the stock one) and editing the installed applications. This is what Kitchens do - right?
When we want to theme things we have to go through and manually edit all sorts of images, resources, compiled xml files, etc.
That all being said why don't people ever just take the source from google (android is open source) and just modify the source to their liking and compile their own ROM? Do people already do this? Wouldn't this making theming a lot easier by just replacing the files before it is all compiled together?
Why don't we just compile a version that lets you theme most things pretty easily - make large parts of the UI skinnable and then people don't have to spend so much time hacking xml files?
Again, this all may be completely wrong and I apologize for wasting your time for reading this if it is...
Just wondering if there is an easier way to do what we are doing
you should do some research on the Cyanogen mod and Android open source project (AOSP)
you're on the right track with where you're going with this, but it's already been done. most ROMs ARE in fact modified versions of 2.1 with edited image files, added applications and such and that's really all we can do, until now at least. some of our devs are working on porting ROMs based off of the Cyanogen mod, which is based off of AOSP.
someone please correct me if I'M wrong =)
I've found the following links to be really helpful:
1) http://forum.xda-developers.com/showthread.php?t=622916 - compiling Hero kernel & AOSP from source
2) http://blog.coralic.nl/2010/01/28/build-eclair-aka-android-2-1-for-hero-from-source/ - blog entry that #1 was based off of
3) http://forum.androidcentral.com/htc...how-build-your-own-kernel-package-source.html - sort of the same thing again, but it's good to read different takes on things like this
4) http://forum.xda-developers.com/showthread.php?t=633246 - very good kitchen
gnarlyc
I could be wrong, but the Google source code will be rather "generic" or all-encompassing. It will (or should) work for ALL Android hardware devices. Problem with that is that it's not optimized for a specific piece of hardware. Same logic applies with compiling your own kernel in Linux. Linux includes hardware support for thousands and thousands of pieces of hardware (and some obscure sh*t at that). Granted, it's not loaded into memory but the code is still in there. When people compile there own kernel, they only include drivers for their video card, their IDE/SATA controllers, their CPU, and so on.
When people start with an ERIS ROM or HERO ROM from HTC, I have to presume that HTC has already stripped out the non-applicable stuff. It's a much cleaner slate to start from.
gnarlyc said:
I've found the following links to be really helpful:
1) http://forum.xda-developers.com/showthread.php?t=622916 - compiling Hero kernel & AOSP from source
2) http://blog.coralic.nl/2010/01/28/build-eclair-aka-android-2-1-for-hero-from-source/ - blog entry that #1 was based off of
3) http://forum.androidcentral.com/htc...how-build-your-own-kernel-package-source.html - sort of the same thing again, but it's good to read different takes on things like this
4) http://forum.xda-developers.com/showthread.php?t=633246 - very good kitchen
gnarlyc
Click to expand...
Click to collapse
Funny you mention that, I just installed an Ubuntu VM so that I could check out the source and start playing around... see what there is to see

How can I modify a cooked rom?

Please excuse my ignorance...
I want to modify an existing blackstone rom (I want to remove some apps).
I downloaded osKitchen Zero but it seems that I can import only an official rom.
Is there another application where I can import a cooked rom? I did some search but couldn't find something in all the load of information existing in xda...
blister969 said:
Please excuse my ignorance...
I want to modify an existing blackstone rom (I want to remove some apps).
I downloaded osKitchen Zero but it seems that I can import only an official rom.
Is there another application where I can import a cooked rom? I did some search but couldn't find something in all the load of information existing in xda...
Click to expand...
Click to collapse
You should be able to delete stuff with htc rom image editor.
http://forum.xda-developers.com/showthread.php?t=377514
As far as I know you Can't, only an official rom can be dumped and changed, cooked roms you are not abble to do it
you should'nt! cooked roms are a piece of art (hard) work. You could ask the chef to cook you a personal rom, buy him a beer or three... or step into the world of cooking, i did. and it's great!
@ blister969
No way!
WBR
Siemens Lover
You can modify cooked roms; look up micro kitchen-it dumps roms, and you can modify the dump (remove a few files; tweak the .hv's) and re-build it. You may need to modify it for your device. You can probably do the same thing with EVK, it just may take a little more work.
@Farmer Ted
If you try dumping ROMs built with platformrebuilder, you don't get the dsm's. That doesn't mind, you can still cook it. But no, you actually can't. All modules loose one S00x containing relocation info.
(Btw, this S00x plus imageinfo.bin is weird anyway, original MS way is more sexy.)
OndraSter is right about reloc info, but I think that you can remove those apps without messing with modules .
Here's another thread on the subject. I'm pretty sure you can re-cook ok, with the missing reloc data. Da_G kicked in on the subject:
Da_G said:
Just a small note to add to this:
The last S00X section in a module is the .CRELOC section. This is used to relocate the module on-device (not used to relocate the module on the PC, in the kitchen, where we do it prior to flashing)
Not having the last s00x means that you wouldn't be able to imageupdate that ROM (because the on-device read/write IMGFS driver would not be able to re-base the module since .CRELOC is missing)
But you can certainly still re-base that module on the PC side prior to rebuilding a ROM. So that function in itself won't preclude you from porting modules from one device to another
Click to expand...
Click to collapse

[Q] Customizing existing NAND ROM

I 'm using [July 24th] [Sense 3.5] Energy™ -.¸¸.·´¯ Sense 3.5 build that just works! NAND ROM that best suits my needs. However I saw [11 SEP] Barebone CM7 v2b and came to idea to make similar thing with this rom for my personal use.
I would also like to implement NativeSD ROM, with that difference of leaving system folder on NAND rom. To be absolutely clear here, I 'm using linux OS and I 'm quite familiar with modifications that have to be done, so I don 't ask for help with that.
I would like to know is it possible to deploy nand rom to android emulator, and than use android emulator for development purposes for further customization, or is there some other tool that can be used for this? I did install android kitchen and I not very pleased with that.
When removing or adding system or market apps is it just enough to add/delete them, or are there some other things that I need to pay attention to?
Also when removing apps how can I see framework dependences to remove them as well if they are not needed anymore by other app?
I hope that is not to complicate to understand what I meant with this topic.
Thanks in advance.
The answer to my question about framework dependencies of a certain *.apk file that I want to remove, can be found in AndroidManifest.xml of that same *.apk file. Although manifest file is encrypted, information about what framework libraries are used can be viewed with aapt command (exp: aapt l -a someapp.apk).
I suppose this is the right way for doing this. Please correct me if there is a better way.

Categories

Resources