Modifying APK in system.img of ROM - Xiaomi Mi 8 ROMs, Kernels, Recoveries, & Other Dev

Hello All,
I am trying to add/edit xml files found inside "assets", "vendor" directories of an APK included in system.img of a ROM.
The APK is available at
system/priv-app/CarrierConfig/CarrierConfig.apk
system/priv-app/CarrierConfig/oat/arm64/CarrierConfig.odex
system/priv-app/CarrierConfig/oat/arm64/CarrierConfig.vdex
Is there a guide to edit the xml files inside the apk, re-compile, put it in a ROM.
I am also interested in making this a Magisk module, So that I can install on top of any ROM.
Please share a guide for it.

Wrong section?

Use APK Easy Tool or BatchApkTool for de recompiling.
For extract Rom use System Extractor WIN master.
All this tool search in Google!

Senior Member what you doing here? Go to to right section!

I had this,
system/priv-app/CarrierConfig/CarrierConfig.apk
system/priv-app/CarrierConfig/oat/arm64/CarrierConfig.odex
system/priv-app/CarrierConfig/oat/arm64/CarrierConfig.vdex
I used apktool to decompile the apk and recompiled it after my modifications. I have also zip aligned and signed the APK.
Can I just replace the apk without modifying or touching the vodex and odex files(I made changes only to the XML files. No java files changed in the modification)?

Related

help with custom rom build

can i take the .apk or the .jar files in the custom mods.zip files and copy them into the framework directory of a rom in the dsixda kitchen? i am not sure if this is the right forum for this.
alucke

Porting themes

Hi,
Is it possible if somebody can guide me on how to port themes.
I tried using the Theme porter and placed the i9100 theme(SystemUI,framework etc) to new folder and in the old folder i placed the i9100g (similar files) and ran the script. With this i do have the system files but i dnt know how to get the META-inf folder for a successful flash.
Is this the correct way to port? (there was a guide which had mentioned about decompiling the framework apk but what exactly do we do with the decompiled folder? since i dnt want to make any changes and just port the theme A-Z.

[TOOL] Create ZipThemer patch from modified APK - Linux only

Hey guys & gals!
Here is a little tool I made.
What it does is take 2 APK files - the original, and the modified/themed one. It then extracts the APK's and collects all the files that have changed from the original in the modified APK. It also adds the new files in the modified APK.
It wont handle changes to the smali code, but any xml or png changes will work fine.
Then it builds the changed files into a zip file that can be flashed using ZipThemer.
To use:
make an empty directory for apkdiff to work in.
create 2 folders new_apk and old_apk and place the 2 files in their respective directories.
Run the script:
apkdiff /system/app Phone
The 2 parameters are:
The folder on your device the APK is located in
The name of the APK file (without .apk on the end)
There are a couple of parameters you may need to adjust at the top of the file.
The result will be a file in the "out" folder which can then be used on other devices to modify the original apk using ZipThemer. This is a lot smaller file than if you redistribute the whole modified APK.
I hope this makes sense to someone!!
I am sure there are bugs in it somewhere, so if you give it a try and it breaks let me know.
Cheers!
Great and useful work mate,
thank you very much!!!

[GUIDE] ROM Tweaking

What you will need:
Basic tools
- Notepad++
- ZIP manager tool like 7zip
Advanced tools
- Cygwin
- smali (assembler/disassembler)
- APKTool/APK Multi-tool
Lets Begin:
Download a ROM (we use CM in this guide) of your choice (don’t forget to get the permissions for it modding from the developer) and extract it. When you extract it, you will see at least two folders and one file
Folders
- system
- META-INF
Files
- boot.img [this is not present in defy/defy+ ROMs so don't worry about it ]
NOTE THAT I AM ONLY GIVING DETAILS ABOUT THOSE FOLDER WHICH YOU CAN REMOVE/EDIT
THE \system\bootmenu\2nd-boot\ FOLDER
In this folder you'll find the kernel [zImage] file of the ROM here you can change it with the one you compiled or by others.
The Tts folder
The ‘TTS folder’ is all about Text-To-Speech. It contains all the files needed by the Android system to get Text-To-Speech working. If you are removing the TTS feature from your ROM, make sure you remove this entire folder and the TTS related apps from the ‘system folder’, as this will save a lot of space.
The WiFi and Usr folders
The WiFi folder contains the drivers required by the WiFi module to function. So i strongly recommend NOT to touch this folder. If you delete any file from this folder, you will mess up the WiFi functionality.
The usr folder contains some miscellaneous but very important stuff. It may contain anything and everything needed by the Android operating system. For instance, this folder contains all the key-mapping. If such files are messed with, your device will be non-functional although it will boot.
The Build.prop
The build.prop file is pretty self-explanatory. Here, you can change the most basic things, like the android version that setting shows. Wondered how people are making 2.3.4 look like 4.0.3 in settings? Its build.prop. Also,you can change what ‘About phone’ shows here.
Other things,you can change things like,how long your wifi scans,how much battery your phone saves while in sleep, Dalvik VM heapsize and default ringtones. If you are wondering what # stands for, it signifies that, the particular line is commented out, and the system does not read it. You can use it add comments to the build.prop. This helps others understand, what is the function of a particular tweak.
A guide for some basic build.prop tweaks can be found here.
Please be aware that, these build.prop modifications are not universal. So, you will have to experiment with the tweaks and their values.
The META-INF folder
This folder contains instructions for the Android Recovery about how to work with the files present in the zip. This folder contains many folders, but the only one we need to edit is the update-script file.
Making Flashable ZIP
In order to create a flashable zip, first zip the ‘system, META-INF’ folder and the ‘boot.img’. Let’s name this zip as ‘update.zip’. Next we need to sign the zip. Get a signer here. Put your update zip in the same folder as the signer. Then run the ‘signer.bat’ file. This will sign your zip file. After the signing process is complete, you can change the name of the zip to your liking.
confused
hi,,,i'm new here,,,,
after reading ur post, actually i can't do this,,,
and i installed miui v5 rom and always find crashing about "android process stopped."
and i can't edit the rom or make update of it because of no jnderstanding it, but i like miui so far.
so, can u give me the link of miui v5 rom that not crash, in order to me just to instal it without editting.
thx so much.
gwesal said:
hi,,,i'm new here,,,,
after reading ur post, actually i can't do this,,,
and i installed miui v5 rom and always find crashing about "android process stopped."
and i can't edit the rom or make update of it because of no jnderstanding it, but i like miui so far.
so, can u give me the link of miui v5 rom that not crash, in order to me just to instal it without editting.
thx so much.
Click to expand...
Click to collapse
Checkout my miui thread I have already posted the original link there
D5+/cm11/1.2GHz.
Sent from Tapatalk app
coolshahabaz said:
Checkout my miui thread I have already posted the original link there
D5+/cm11/1.2GHz.
Sent from Tapatalk app
Click to expand...
Click to collapse
which one???
is it the official rom from miui site or edited rom you created??
actually its take too long doenloading from official site. but rom i doawnloaded is always crashing android.process.stopped.
gwesal said:
which one???
is it the official rom from miui site or edited rom you created??
actually its take too long doenloading from official site. but rom i doawnloaded is always crashing android.process.stopped.
Click to expand...
Click to collapse
The one I edited had that prob of crashing, n the one on official site is about 240mb ty its taking time
D5+/cm11/1.2GHz.
Sent from Tapatalk app

Can someone post the deodexed version of the robin .apks?

All it takes is for you to take a backup and run the deodex wrapper on your device creating classes.dex's files in all you'r apks allowing to edit the smali. I would do it myself but I currently dont own the device.
Pneuma1985 said:
All it takes is for you to take a backup and run the deodex wrapper on your device creating classes.dex's files in all you'r apks allowing to edit the smali. I would do it myself but I currently dont own the device.
Click to expand...
Click to collapse
Here you go i included the app, dex, framework, odex, priv-app you will need 7-zip because i compressed it from 850mb's to 350mb's.
https://www.androidfilehost.com/?fid=24549084345925845
That does not have all the .dex files in the dex folder. Thus I can not access the smali... Which is what I was after a certrain method within the netxbit systemUI smali. Though it did give me the .dex files of several apks just not the exact one I was after. How do I access the systemUI .dex. It's been a long time since I've made roms and deodexed apks especially now with art. I'm really after the UI .dex file so I can gain access to a specific method within in it. If you could post that I'd be ecstatic Something I decompile to track down smali methods I want to recreate in my own custom 6.0 SystemUI.
Nvm Ticklefish's tool did the job http://www.mediafire.com/download/czod7v081w0ravt/TickleMyAndroid+-+v13.3.0.exe
The only tool out of all the deodexing tools that worked!!!!! The only one! Aside from the linux kitchen but I wasnt setting that up... Mess up my linux install no thanks!
FM radio
Is this FM radio apps

Categories

Resources