Edit Custom Rom (help to remove apk's) - Sony Ericsson XPERIA X10 Mini

Does anyone know an idiot's guide/tool for unpacking a rom, removing unwanted apk's and then repackaging it suitably for install. I can unzip and remove the apk's from the system/app but the problem I have is zipping the package up suitably for install, I understand that the package needs to be signed and I have seen a few guides using openssl and SignAPK but couldn't get a package that would install.
I know I can uninstall some of these apps using an uninstaller app but I would prefer they just weren't in my rom in the first place so I have a relatively clean rom - my phone is basically a glorified mp3 player that occasionally makes some calls and send the odd text so there are a fair few things I just don't need to be installed on the phone.
On my mini pro I'm using the SonyStyle GB rom
http://forum.xda-developers.com/showthread.php?t=1151499
Any help will be appreciated.

stikkki said:
Does anyone know an idiot's guide/tool for unpacking a rom, removing unwanted apk's and then repackaging it suitably for install. I can unzip and remove the apk's from the system/app but the problem I have is zipping the package up suitably for install, I understand that the package needs to be signed and I have seen a few guides using openssl and SignAPK but couldn't get a package that would install.
I know I can uninstall some of these apps using an uninstaller app but I would prefer they just weren't in my rom in the first place so I have a relatively clean rom - my phone is basically a glorified mp3 player that occasionally makes some calls and send the odd text so there are a fair few things I just don't need to be installed on the phone.
On my mini pro I'm using the SonyStyle GB rom
http://forum.xda-developers.com/showthread.php?t=1151499
Any help will be appreciated.
Click to expand...
Click to collapse
Open the zip in something like 7-Zip or WinZip or windows or whatever the default archive manager is on linux, delete the files you want and close it then install. that's it, signing is done on creation by the dev and isn't like a MD5 so it doesn't matter if you modify it
X10man

what i do is i have winrar and i just double click the rom zip file then go to system then go to app then delete the app (and the odex file if it has one) that simple and if you want to add an app just hit add (provided your still on system>app folder) browse to the apk file you want to add then hit hit ok. hope that helps

Cheers guys - from what I had read I thought I had to re-sign the package once I had edited it.

Related

[Q] Installing Calendar.apk on devoid (and the rest of the gapps)

I like the minimal devoid ROM since I can install only the apps that I actually use, but I have one app that I can't figure out how to install: Calendar.apk, the stock Android calendar.
Things I've tried:
1) Installing the apk from /sdcard/void/resources/gapps/apk/ from my void installation. This fails in the App Manager with the completely unhelpful message: "Application not installed"
2) Installing the gapps-gb package from mik_os's CM 7 port. This can be flashed and some of the apps install just fine, but not the calendar.
3) Installing the gapps-mdpi package from CM 6. This seems to be a better fit with the Froyo in devoid but like above, it installs a great many of the gapps, but not Calendar.
Has anyone managed to install the stock Android Calendar program under devoid? How?
flash the file attached,
it contain some originals apps:
Calendar
SoundRecorder
MoviePlayer
MusicPlayer
It looks like this contains only the CalendarWidget.apk. I flashed it anyway and it indeed does install the CalendarWidget along with the other apps, but not the calendar application. Thanks, though.
Your zip did give me the idea that I could just try to copy the APK files into /system/app. This worked. Now I can get started adding the rest of the apps I need.
can you teach me how to add those gapps in more detail? i have copied them to system/apps, then what's the next?
Hello, you only have to follow the instructions from the http://forum.xda-developers.com/showthread.php?t=887281
Tutorial: How to flash only some sapps
1. Grab the sapps/gapps package
2. Extract it
3. Go to the extracted folder "/system/app/" and delete the applications you don't want to flash
4. Use the above program (zipsigner) to create a CROM.zip, put the extracted files there so you have 2 folders on the root of the zip: META-INF and SYSTEM. Then sign it and it should create a CROM-s.zip.
5. Rename the CROM-s.zip to MySapps.zip, put it in sdcard and flash.
Click to expand...
Click to collapse
I attached the file that I used to flash calendar, and other apps
Calendar
Thanks a lot. This solved my problem for devoid
thank you very much ! iam enjoying my phone with the calendar !
Sent from my LG-P500 using XDA App

[Q] Editing an APK, any APK.

EDIT: Figured it out.
Care to share?
Yeah, will be nice if you could share this information with others
aitorTheRed said:
Yeah, will be nice if you could share this information with others
Click to expand...
Click to collapse
Man, I hate it when people do that...
1. Search for APK Manager in XDA and install it on your PC
2. Download and Install the Android SDK kit on your PC
3. Follow the instructions for APK Manager and place the APK file in the modding folder
4. Open APK Manager and select Decompile APK (Your APK file will be placed in a separate folder for you to work on)
5. Change what you want to change in the APK
6. Recompile the APK and sign it (unless it's a system file like framework, those are not signed)
A lot more is involved in modding an APK file and you really should know something about how the files inside the APK work before you go changing things, but in a nutshell, that's the basics.
Hope that helps!
What I have learned.
I had a specific question, but here is what I can tell you.
1. Setup APK Manager, it saves a lot of command line typing.
2. Pretty much always use option 9 and 11, never 1 or 3.
3. If you are simply changing graphics and not smali or XML files, don't use this, open it in 7zip and drag the files. Decompiling changes the image darkness sometimes.
4. Unless you are working on your own apk file, always say yes to 'is it a system apk', when it asks you to keep existing files, say yes. Delete from the 'keep' folder what you edited.
5. If you edit XLM files, delete resources.arsc from the file, this is where they all get compiled to.
6. You can use this for jar files, just rename to apk then back to jar when finished.
7. If you get an error try using option 20 to increase the memory to 1024.
8. If you edit jar files, delete classes.dex in the 'keep' folder when compiling.
9. Treat all files as signed system files (as noted above) and you will be much safer. If the file has a signature on it, this will save it.
Thanks for the info
Is there anything that can install system files. They won't install with ap manager so does it have to be pushed?
Sent from my Desire HD using XDA Premium App

[Q] Manual deodex an rom before flashing?

I'm searching for a simple way how can I deodex any rom. My idea is to rename the *.odex file to classes.dex and put it into the apk/jar archive using a simple archive manager. Will this work? I don't like any scripts to do that, will make it manual before flashing the rom. And need I to sign the apk/jar files (I think the normal apk files need that, but what witch the framework? Need it too to be resigned?).
no use xultimate
Sent from my GT-S5830 using xda premium
sometimes scripts is better to make your life easier
btw try dsixda android kitchen. its my favorite tool/script to deodex
Hmm ok will try first the dsixda android kitchen, I see it has version for Linux. But I will understand how this script works?
EDIT
Ok, now I see, it uses baksmali and samli to deodex. Thanks to all, will test it tomorrow.
Ok, after using the dsixda android kitchen and deodexing the framework (and SystemUI.apk, not more) and flashing the ROM I got an bootloop (wipe doesn't help). Her is my logcat http://pastebin.com/DtfChnPp , can some help, what did I wrong? I have only after deodexing apply the volume mod and the Pdroid patch, I am working on this rom http://forum.xda-developers.com/showthread.php?t=1360889
try this
download xultimate, theres a thread about it somewhere. unzip it and connect your phone with the rom thats .odex http://forum.xda-developers.com/show....php?t=1360889
next
once connected click on opition 5 which will pull all the apps and framework files from your phone and will deodex all the files and store them in the folder called "done_app" and "done_framework" may take up to 15mins
next
change the folder names of the done folders to "app" and "framework" and have both folders and the rom.zip that you installed pre at hand, in your case
http://forum.xda-developers.com/show....php?t=1360889
Then open the rom.zip up with 7zip and then click on system folder and drop "app" and "framework" folders into the rom.zip so your swaping the the folders with the .odex files for the deoxed ones you just did. put it on sd-card. wipe, mount system and data and install.
correct me if im wrong.
hope this works.

Multiple app install: will this work?

Hi
I'm looking for an easy way to batch install all of my already backed up applications on external SD (in *.apk format) after new rom flashing. My phone is rooted (running RR 2.7). what if using a root explorer I just copy all the apk files to data\app and copy some of them to system\app and then reboot the phone? Will all of these application be automatically installed, while apk's copied to data\app will be installed as user apps, and those copied to system\app will install as system apps? Will this work? Is there a problem in this method? If so I may create a CWM based installer that will do this automatically...
I'm talking about 400 apps, about 600MB in total size//
Thanks
How are they backed up? What did you use to do it? I use Titanium Backup. The paid version allows batch operations.
Sent from my SPH-D710 using xda premium
boborone said:
How are they backed up? What did you use to do it? I use Titanium Backup. The paid version allows batch operations.
Sent from my SPH-D710 using xda premium
Click to expand...
Click to collapse
I used an app called File expert. It can simply find the apk file used in the installation and back it up. I can reinstall the app with the backed up apk. I also tried copying a new apk file to data/app and after restarting the app did install correctly. So I want to use this method to restore all of my apps automatically by creating a CWM zip installation. I need to know if this method is safe and will not cause problems...
Thanks
EB10000 said:
I used an app called File expert. It can simply find the apk file used in the installation and back it up. I can reinstall the app with the backed up apk. I also tried copying a new apk file to data/app and after restarting the app did install correctly. So I want to use this method to restore all of my apps automatically by creating a CWM zip installation. I need to know if this method is safe and will not cause problems...
Thanks
Click to expand...
Click to collapse
No need to do any of that crap and mess around. Just use Titanium Backup Pro (paid version) and you can backup all your apps plus the app data so they keep all their settings etc. Then when you install a new rom you can batch install them all back in couple of clicks.
EB10000 said:
I used an app called File expert. It can simply find the apk file used in the installation and back it up. I can reinstall the app with the backed up apk. I also tried copying a new apk file to data/app and after restarting the app did install correctly. So I want to use this method to restore all of my apps automatically by creating a CWM zip installation. I need to know if this method is safe and will not cause problems...
Thanks
Click to expand...
Click to collapse
Don't know that app. You can define the backup folder in TiBu to reinstall your apps that way. Or iirc Rom Toolbox will take a batch of apps and create a cwm zip file to batch install.
Sent from my SPH-D710 using xda premium
EB10000 said:
I used an app called File expert. It can simply find the apk file used in the installation and back it up. I can reinstall the app with the backed up apk. I also tried copying a new apk file to data/app and after restarting the app did install correctly. So I want to use this method to restore all of my apps automatically by creating a CWM zip installation. I need to know if this method is safe and will not cause problems...
Thanks
Click to expand...
Click to collapse
Using CWM zip installation is actually the best method. It is safe and faster too.
Thanks. I'm familiar with TB and MB. I do not need to restore the app's data. I'm just looking for a way to install all my market apps without actually using the market. I noticed that when you reboot the phone, any new apk file in either system/app or data/app gets installed automatically. So I thought maybe I take a CWM setup file (zip with simple copy to system + data updater-script)' and add all of my backed apk's into the data/app directory then I can install this zip file right after I flash a new rom file. For some reason, CM9 recommends that you do not use TB. I also noticed that dev's use this method to add additional apps to their rom.. I just need to know that this method is ok to use and not cause problems like acquire extra space by creating duplicates of each app (I notice using this method that sometime the original apk I copied was reset to a 0Kb file, and a new apk that starts with the name "com.something.something.apk" is created instead. Is this normal?)
Thanks
boborone said:
Don't know that app. You can define the backup folder in TiBu to reinstall your apps that way. Or iirc Rom Toolbox will take a batch of apps and create a cwm zip file to batch install.
Sent from my SPH-D710 using xda premium
Click to expand...
Click to collapse
Do you mean this app:
https://play.google.com/store/apps/details?id=com.jrummy.liberty.toolbox
???
I already have it (paid version). I couldn't find a way to creat CWM zip file... Am I missing something?
Thx
EB10000 said:
Do you mean this app:
https://play.google.com/store/apps/details?id=com.jrummy.liberty.toolbox
???
I already have it (paid version). I couldn't find a way to creat CWM zip file... Am I missing something?
Thx
Click to expand...
Click to collapse
I'll help you create a CWM zip template. I'll upload it in about 3 hrs time as soon as i get to my pc
This is a CWM.zip I created for you.
How to:
1. Open the zip file using 7zip, winrar or similar apps (don't extract it)
2. Copy your users apps to data/app, and copy system apps to system/app
3. Close the zip file.
4. Flash the zip file via CWM recovery.
enjoy.
EB10000 said:
Thanks. I'm familiar with TB and MB. I do not need to restore the app's data. I'm just looking for a way to install all my market apps without actually using the market. I noticed that when you reboot the phone, any new apk file in either system/app or data/app gets installed automatically. So I thought maybe I take a CWM setup file (zip with simple copy to system + data updater-script)' and add all of my backed apk's into the data/app directory then I can install this zip file right after I flash a new rom file. For some reason, CM9 recommends that you do not use TB. I also noticed that dev's use this method to add additional apps to their rom.. I just need to know that this method is ok to use and not cause problems like acquire extra space by creating duplicates of each app (I notice using this method that sometime the original apk I copied was reset to a 0Kb file, and a new apk that starts with the name "com.something.something.apk" is created instead. Is this normal?)
Thanks
Click to expand...
Click to collapse
Don't install all your apps to system. Why would you want to da that?
EB10000 said:
Do you mean this app:
https://play.google.com/store/apps/details?id=com.jrummy.liberty.toolbox
???
I already have it (paid version). I couldn't find a way to creat CWM zip file... Am I missing something?
Thx
Click to expand...
Click to collapse
I thought that might be the one, guess not. I'll ask in another thread.
But this guy was kind enough to make one for you. Ought to slap him a thanks.
Sent from my SPH-D710 using xda premium
---------- Post added at 11:45 AM ---------- Previous post was at 11:42 AM ----------
Jokesy said:
This is a CWM.zip I created for you.
How to:
1. Open the zip file using 7zip, winrar or similar apps (don't extract it)
2. Copy your users apps to data/app, and copy system apps to system/app
3. Close the zip file.
4. Flash the zip file via CWM recovery.
enjoy.
Click to expand...
Click to collapse
Thanks man. Hell I'll even take a bite of that.
Sent from my SPH-D710 using xda premium
Jokesy said:
This is a CWM.zip I created for you.
How to:
1. Open the zip file using 7zip, winrar or similar apps (don't extract it)
2. Copy your users apps to data/app, and copy system apps to system/app
3. Close the zip file.
4. Flash the zip file via CWM recovery.
enjoy.
Click to expand...
Click to collapse
Thanks Mate!
tested it with a few apps and it worked great. Is there a file size limitation to cwm.zip? If I add all my apps the zip files grows to about 350MB
Thx
EB10000 said:
Thanks Mate!
tested it with a few apps and it worked great. Is there a file size limitation to cwm.zip? If I add all my apps the zip files grows to about 350MB
Thx
Click to expand...
Click to collapse
Nah. Just take longer.
Sent from my SPH-D710 using xda premium

[Q] How should I de/recompile a system app? What did I do wrong?

Hi,
So the situations is like this:
Just got a new LG Nexus 4, NFC enabled, GREAT!!!!
But then I start using it, and the NFC sound (everytime the phone reads a nfc-tag it makes an sound) annoys me beyond belief.
So I start looking around, it seems there's no solution, except recompiling the app.
So I learn how to compile an app (noob here), using this guide: http://forum.xda-developers.com/showthread.php?t=1860115
I'm up to the point where my apk is decompiled, and I have modified the sound files, located in my decompiled files folder respectively at res/raw/start.ogg & res/raw/end.ogg.
I modded the files using audacity, lowering the volume to zero, used them to replace the original .ogg files. The file size is a bit smaller as the original ones (1Kb difference).
Next I use the recompile command: apktool b decompiled_apk_folder_with_modified_files modded_apk_file.apk
So now I have the new nfc apk file, called NfcNci.apk, with which I replace the original file in /system/app.
Next up I reboot my phone into recovery, wipe all cache and dalvik cache, and reboot again.
First thing that pops up on my screen is a force-close message, saying that the nfc-service force closed.
Anyone who can tell me what I did wrong? Or how I can fix this?
Attached are: my decompiled-files-folder (compressed to zip)
the original NfcNci.apk file
my modded NfcNci.apk file which causes the FC's.
Any help will be greatly appreciated!!!!
S.
Looks like you're still on 4.2
The latest NfcNci.apk has some more files.
And your apk is missing the META-INF folder.
I guess that this is the problem.
But you should use "adb logcat" to ensure we're on the right track.
Micky
1 thing i would recomend is not using the actual apk you just built. instead, open your new apk with a file manager such as 7zip and remove your newly compiled files out of it, then put them into the original apk from your rom using 7zip as well! thus keeping the apk's original signature
try to copy the least amount of files from one to another, so to be safe only pull out your new .ogg files, then put them into your original apk! hope this helps
ldrifta said:
1 thing i would recomend is not using the actual apk you just built. instead, open your new apk with a file manager such as 7zip and remove your newly compiled files out of it, then put them into the original apk from your rom using 7zip as well! thus keeping the apk's original signature
try to copy the least amount of files from one to another, so to be safe only pull out your new .ogg files, then put them into your original apk! hope this helps
Click to expand...
Click to collapse
Hi, I tried this, installed 7zip, and double clicked the original apk, I opende the res/raw/ directory, and only copied the files I was using: start.ogg & end.ogg. Then I close 7zip, and send the file to my phone. But as soon as I it them to /system/apps on my phone, and reboot to recovery, wiping the dalvik cache. I get FC's on reboot (NFC-service has FC'd).
Any reasons for this?
Thanks for the help, both of you!
BTW: I'm on Android 4.3 JB

Categories

Resources