Edit And Signing Roms - myTouch 3G, Magic Android Development

This may not belong in this section but it has relevance.
I have a 32a HTC Sappire with the blueberry hero rom latest version installed.
lets say the following
i like the ROM but there are some programs pre-installed that i do not need or will ever use.
how can i remove from the update.zip the programs that aren't needed (ie = plurk, kkbox, twitter, peep, pdf viewer, etc...)
what can not be removed???
after that.
how do i SIGN the update.zip so i can install it to my phone.
please let me know. thanks a lot

Dude
If you search for "signing" you will find the answer...

why not to remove the aps using adb???
Probably those aps are located in /system/app/ so you just should do the next thing:
Code:
adb shell
cd /system/app
ls
This will show you the current installed aps, you need to do this in order to find the name of the aps insatlled so you can later uninstall them...
Now open another adb console and do the next thing:
Code:
adb remount
adb shell rm -r /system/app/nameoftheapp.apk
Where anemoftheapp.apk is obvoiusly the name of the app you want to remove...
That should do the trick... And it's easier than having to sign a rom...

these apps are preinstalled in with the rom. so i can not just go to app and remove them.
can i remove them via adb console like you stated?
i have already done a search nothing come up... thats why i posted it up. sorry if i missed it

Yes - You can remove them as above.

Related

Replace default applications?

I was wondering if its possible to replace the default applications?
Specifically, I'd like to replace the built-in "Alarm clock" app with Koush's excellent "Klaxon" app.
Anybody know how to do this? Can it be done with ADB push/pull?
I'm running JF's rooted RC30, 1.2, with the engineering booloader.
cheers, and happy new year!
-- michael
adb remount
adb shell rm /system/app/AlarmClock.apk
adb shell rm /system/app/AlarmClock.odex
adb push Klaxon.apk /system/app
That's one way to do it. Klaxon will then survive hard resets.
The recommended way to do it is to extract the system directory to your computer. Change the files around in the same manner as above, and use "mkyaffs2image -f directory image" to create a new image. Then use fastboot to flash that image. That's a bit more complicated though.
Koush said:
adb remount
adb shell rm /system/app/AlarmClock.apk
adb shell rm /system/app/AlarmClock.odex
adb push Klaxon.apk /system/app
That's one way to do it. Klaxon will then survive hard resets.
The recommended way to do it is to extract the system directory to your computer. Change the files around in the same manner as above, and use "mkyaffs2image -f directory image" to create a new image. Then use fastboot to flash that image. That's a bit more complicated though.
Click to expand...
Click to collapse
koush, thats a good idea! i want to try that. hey question, did you get the wireless in cupcake to work?
korndub said:
koush, thats a good idea! i want to try that. hey question, did you get the wireless in cupcake to work?
Click to expand...
Click to collapse
Nah, I didn't play around with it for that long.
Koush said:
Nah, I didn't play around with it for that long.
Click to expand...
Click to collapse
me either. too bad that its not complete. would be nice to have the native keyboard...
Koush said:
adb remount
adb shell rm /system/app/AlarmClock.apk
adb shell rm /system/app/AlarmClock.odex
adb push Klaxon.apk /system/app
That's one way to do it. Klaxon will then survive hard resets.
The recommended way to do it is to extract the system directory to your computer. Change the files around in the same manner as above, and use "mkyaffs2image -f directory image" to create a new image. Then use fastboot to flash that image. That's a bit more complicated though.
Click to expand...
Click to collapse
Would it be possible to do this all through cygwin, or would I need a full linux VM?
s0niqu3 said:
Would it be possible to do this all through cygwin, or would I need a full linux VM?
Click to expand...
Click to collapse
Those commands would work in Windows or Linux.
Koush said:
Those commands would work in Windows or Linux.
Click to expand...
Click to collapse
Hi,
I know the adb commands will work, I apologize for not being more specific, I was wondering if it would be possible to extract the system image, and build a new one without a linux vm.
s0niqu3 said:
Hi,
I know the adb commands will work, I apologize for not being more specific, I was wondering if it would be possible to extract the system image, and build a new one without a linux vm.
Click to expand...
Click to collapse
Yes, the mkyaffs2image tool is available as a Windows binary. I've seen it floating around this forum somewhere. Or you can ask JesusFreke to build you the executable; he has Cygwin set up properly.
Ok, time for another question that's semi-related.
Can anyone think of any reason why removing the "email" program can't be removed?
I only use the gmail app, and can't foresee needing the regular email app as gmail can check any other accounts I ever setup.
I tried push some app to system/app and I find that all app add to system/app will be alway active (as running app or service)
s0niqu3 said:
Ok, time for another question that's semi-related.
Can anyone think of any reason why removing the "email" program can't be removed?
I only use the gmail app, and can't foresee needing the regular email app as gmail can check any other accounts I ever setup.
Click to expand...
Click to collapse
I second the question. I'd like to remove the stock Email and replace it with K-9.
danguyf said:
I second the question. I'd like to remove the stock Email and replace it with K-9.
Click to expand...
Click to collapse
So far I have removed:
Alarm Clock
Voice Dialer
Email
IM
Talk
com.amazon.mp3
Sound Recorder
Camera
The stock Browser with the auto-rotating one
Stay away from sync/service packages (Im*, calendar, gmail, gtalkservices, etc) as you will find yourself with some interesting errors and malfunctioning apps. Leave MyFaves be as well (documented elsewhere in the forum); if you want it gone, install ADP1.

How to Change Music Widget in any Cupcake Build

Always perform a nandroid backup before attempting any mods.
This is a tutorial on how to change the music widget to the one of your liking. It doesn't matter if you have the Dude build and want the G build widget or have the G build and want the 1.5Hr1 widget. This will work for any cupcake (Android 1.5) user who is not happy with their current music widget. I use a windows PC and I am not a Linux guru so I'm not going to attempt to tweak my tutorial for Linux users. Hopefully it's not to hard for them to figure it out from this. (I think it's just file path differences, maybe?)
First step is to have ADB commands working on your computer. Follow this link if you don't know how to do this.
http://forum.xda-developers.com/showthread.php?t=502010
Now that you have ADB, you have to download the appropriate music player/widget that you prefer.
This one is for installing the dark blue music widget with the off-center play/pause button and the transparent record and needle logo. My personal favorite for looks, but has a play/pause with a easy to miss touch area.
http://rapidshare.com/files/227653807/Music_fancy_widget_G_build.apk
This one is for installing the plain white and pale blue music widget with rectangular shape and the large play/pause button with it's large touch area.
http://rapidshare.com/files/227653907/Music_standard_build.apk
This third option is for future development. You can "harvest" a third music widget/player from a third source that doesn't yet exist using the ADB pull command. Lets say your using build X, but build Y has a theme available and you love the themed music widget on themed build Y. What you do is perform a nandroid backup of your current build so you can return to it later and install build Y and then theme it. (Don't waist your time setting up your settings because you won't be on this build for long. Just make sure USB debugging is enabled in settings > Applications > Development so you can use ADB.) You can skip this step if you have access to a friends phone who's already running the music player/widget you want. Connect the USB cable to the phone and go into where you run your ADB commands in Command Prompt on your PC. Type in this command.
adb pull system/app/Music.apk c:\your_path_here
Click to expand...
Click to collapse
The "system/app/Music.apk" part of the command is case sensitive. This will create the Music.apk with the widget you want at the path you specify. Next you can use Fastboot to restore your nandroid backup of build X. (Nandroid saves everything. It's as if you never left.)
Next step is to rename the downloaded file "Music.apk". It's case sensitive and take note of the folder path it's in.
Next, enter the following ADB commands from the appropriate place in Command Prompt. (Start > Run > type "cmd")
adb remount
adb shell rm -r system/app/Music.apk
adb push c:\your_path_here\Music.apk system/app
Click to expand...
Click to collapse
"system/app/Music.apk" and "system/app" parts are both case sensitive.
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
pgiuoco said:
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
Click to expand...
Click to collapse
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
FYI - I have Apps2SD and I used the above command. Guess that doesn't make a difference, assuming because the symlinks say so? I'm such a Linux noob!!!!
bigballa said:
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
Click to expand...
Click to collapse
Yes, different looking gui, the Dark Blue is very nice!
P.S. Nice write up!
setzer715 said:
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
Click to expand...
Click to collapse
Wow, that was a BIG OOPS! Thanks for catching that. I fixed the original post.
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
djdeviance said:
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
Click to expand...
Click to collapse
I'm not a frequent Linux user, but I know a couple of commands. You could download the apk file to your sdcard and try this. This method is not recommended!
su
rm -r system/app/Music.apk
Click to expand...
Click to collapse
This will delete your old music player. Next, you can just install the new music player apk through Apps Installer or whatever you use in it's place. This will allow you to use the new music player as if it was any other 3rd party app. However, I recommend uninstalling it and doing it through the ADB push when you get home.
yeah the app installer method didn't work for me
pgiuoco said:
yeah the app installer method didn't work for me
Click to expand...
Click to collapse
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
testing567 said:
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
Click to expand...
Click to collapse
Haha ended up doing it at home anyways. =D Yeah i was kinda doing nothing at work. So as usual I started fidgeting with my phone.
the steps given in the first post work perfectly...!!!
i am on ADP1.5H A2SD...Gud Work...THNX..!!
If someone could post screenshots of the different UIs, that'd be great.
For some reason, when I pushed the Music.apk it worked fine, but when I tried to do the same thing with the CalendarProvider.apk, it didn't....
This method works for me as well. How do you take screenshots with the new builds?
CalendarProvider.apk... Just do a normal .apk installation.
Does this only work for Rooted phones as when I try it I get permission denied
Code:
C:\android\tools>adb shell rm -r system/app/Music.apk
rm failed for system/app/Music.apk, Read-only file system
C:\android\tools>adb shell
$ su
su
su: permission denied
$
jayaustn said:
If someone could post screenshots of the different UIs, that'd be great.
Click to expand...
Click to collapse
i second this idea
moosefist said:
i second this idea
Click to expand...
Click to collapse
I third it
music.apk
can someone post some different download links for the two different music.apk builds? rapidshare has always hated me and will still not let me download either of them saying that my ip address is already downloading something. thanks.
Can someone post pics of all the music widgets in order to compare them?

The proper way to remove a system applications

Dears,
I'm using the last Cyanogen and I would remove some applications that stay in /system/app. I know that I can do this just with:
- rm /system/app/NAME.apk
- rm -r /data/data/NAME
but in this way the application data remains in /data/system/packages.xml: I don't want to manually change this file. Is there a more clean and automatic way to do that?
For the applications in /data/app, I can use 'adb uninstall NAME' but it seems that is not appliable to the ones in /system/app. Even after a 'adb remount'.
Any suggestions?
Just delete them.
anyone knows?
i wanna get rid of the default IM.. and amazon mp3
I repeat myself: Just delete them.
It isn't dangerous or "unclean".
Just be a little aware that some apps might seem superfluous, but actually do things other than the part you see. For example, you can't delete the stock Mms.apk and use ChompSMS as your sole SMS application - the stock app also contains the framework for the device to receive SMSes at all. I would rename files rather than deleting them, i.e.
mv thingyouwanttodelete.apk thingyouwanttodelete.old
rather than
rm thingyouwanttodelete.apk
because you can always then put it back afterwards if you find something doesn't work afterwards.
I think Cyanogen latest rom has the system app's folder as read only. So you would need to remount the drive as Rewriteable to make any changes to the files.
njakobs said:
I think Cyanogen latest rom has the system app's folder as read only. So you would need to remount the drive as Rewriteable to make any changes to the files.
Click to expand...
Click to collapse
what are the steps to remount as rw?
chmod +rw?
farbird said:
what are the steps to remount as rw?
chmod +rw?
Click to expand...
Click to collapse
-bash-3.2$ ./adb remount
remount succeeded
adb remount - remounts the /system partition on the device read-write
adb root - restarts adb with root permissions
You can delete stuff in the update.zip then just resign it. I wouldnt delete any com.**** stuff or htc.**** except widgets(on hero) always copy the update zip before you start editing so you can always add what is needed
Start asking your questions in the right sub-forum (Q&A) (Theme) or even in (General), or i will be forced to ban you for 3 days or till you learn.
Thanks
Thread Trashed!!

Question about adding stock apps back

I have read and still don't understand how to add back apps like Sprint TV. I have them all saved on my computer I just do not know the commands to get them back into the phone. Do the apps I want to ad back need to be in a certain dir on my computer first. If someone could explain or either point me to a thread that explains this I would really appriciate it.
Seems I found an easy way to add sprints, htc's apps back into the phone once removed. I saved all of them on my computer and used HTC Sync to install the app back. I removed Nscar as a test using root manager, rebooted and it was gone, then opened up HTC synch and added it back. Not sure how to get the odex files back in but it works with apk files.
AFter testing it om HTCfootprints it would not install this. Installed Nscar with no problems.
I am also trying to figure out how to add sprint tv back onto my Hero. I see that people are saying to use adb push, but I can't seem to get it to work. I just rooted with the new fresh rom and everything is great, I just want to add back sprint tv. Any help would be appreciated, thanks
Im a total noob, but I got it the apps back on this way:
Go to the directory where the ADK Tools directory is. Then the following commands:
adb shell
su
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
chmod 777 /system
chmod 777 /system/app
exit
exit
Then I copied the .apk files that I wanted to push to the tools directory
I am in.
Then did this:
adb push Sprint_TV.apk /system/app
I found it is case sensitive, so make sure you type the filename exactly.
I rebooted my phone and the apps (such as Sprint TV) were back.
I hope this helps, like I said, I spent an hour trying to figure it out, but this worked for me.
I would not recommend doing a chmod 777 on your system or app directory. Not that anything bad will necessarily happen, but it's generally not a good idea to mess with system file permissions when you don't have to.
Your procedure would work fine without those commands at all, in fact. You don't even need to enter the shell; just adb remount and then adb push.
those instructions worked perfectly. Thanks a ton.
I tried this with HtcFootprints. I removed the widget as well. When I added all 4 back in I can see the widget for footprints, but the footprint icon does not show up in the apps section.
Another thing of intrest. When I added Nscar back using HTC Sync, it now shows up as a third party app. It is no longer a system app and I can uninstall it like a market app.
Ok scratch that I did the Footprints again and the Icon is now there Thanks a Ton
I was able to push HtcTwitter.apk and .odex. i cannot get the widget to show up in the add HTC widgets menu. Any ideas?
Well, after trying my hand at update/rom modding with some success... I'm willing to take a shot at making update.zip files to easily flash individual stock apps back onto your phone. That's if there's any interest.
obelisk79 said:
Well, after trying my hand at update/rom modding with some success... I'm willing to take a shot at making update.zip files to easily flash individual stock apps back onto your phone. That's if there's any interest.
Click to expand...
Click to collapse
That would be great and very helpful to many
Easy Peasy App Install
I just copied the files to my SD card. I then browsed to the SD card folder using Linda File Manager and "clicked" the file. It asked me if I wanted to use Linda File Manager or Package Installer. I selected Package Installer and it proceeded to installed the package for me. Not need to get into the console or use any commands.
VOILA!

2.1 HTC.IME stock keyboard

Does anyone have a link to this if there is one floating around I cant seem to find it. Any help would be great I cant stand the lag in the xda mod kb
here you go. I also like the stock keyboard better. View attachment HTC_IME.apk
Stock HTC Keyboard
Here you go.
EDIT: Someone beat me to it.
Thanks guys
Thank you very much!
alexthearmo said:
here you go. I also like the stock keyboard better. View attachment 322118
Click to expand...
Click to collapse
This is also the mod!
I tried to install this onto my phone by opening it with the File Explorer, but it won't install... what am I doing wrong?
The stock HTC one must not be an installable apk. You probably need to adb push to /system/app
c00ller said:
The stock HTC one must not be an installable apk. You probably need to adb push to /system/app
Click to expand...
Click to collapse
I was afraid that would be the case. In fact, I never really became familiar with how to "adb push" apps and was never able to really find clear instructions. Is it just an alternative method of installing apps? Can they be removed by settings > applications > manage applications > uninstall?
dvdqnoc said:
I was afraid that would be the case. In fact, I never really became familiar with how to "adb push" apps and was never able to really find clear instructions. Is it just an alternative method of installing apps? Can they be removed by settings > applications > manage applications > uninstall?
Click to expand...
Click to collapse
adb push is just a way to literally shove files onto your phone. Think of it as just copy from your desktop to paste into internal memory, no interface involved. I guess that's why it's called "push," there are no questions asked, the job is done instantly.
To do it, first place the apk file in your sdk tools folder. Make sure USB debugging is on (Settings > Applications > Development) and connect phone to PC
1) Start > Run > cmd
2) In the terminal type "adb devices"
3) You should see your device serial no listed there. If not, don't proceed.
4) Type "adb remount". It should say remount succeeded
5) Type "adb push HTC_IME.apk /system/app" (capitalization matters, I believe)
That should be it. If you don't see the new keyboard in Location and text settings, just restart your phone and it should be there.
And as these are system files, they can't be uninstalled the way you mentioned. But removing them is very simple. Repeat steps 1-4 above, but then to remove a file type "adb shell rm /system/app/xxxx.apk" where xxxx.apk is whaver apk you want to remove. This is how you remove stock programs like Sprint Nascar, Stocks, and all that other junk.
I used eoe appinstaller no problem. Did you unzip the file? You gave to install the clucker apk and thw keyboard. The black mod is good!!
Sent from my HERO200 using XDA App
Edit: Wrong forum...

Categories

Resources