how can merge both apk+data to only apk for non rooted devices - SuperSU

hello
i have original apk
and also have modified xml files of it which located in
/data/data/app name
how can i marge both for one apk
or how can i make its data -- to apk file to install it on non rooted devices

Related

Manually Installed dowloaded apps

Hi,
I'm customized my own rom with apps peviously get from market (Premiere, Dizzler, Vingtminutes, better terminal etc...)
Some of them are already in apk format, some others ( like Prermiere) are in zip format.
As I know that the apk and the zip format are quite the same I just renamed the zip to apk.
But after the reflashing the old zip files where not installed.
So I opened them to see that the folder META was not present. So I try re-signed them with the signapk pak, but the result is the same .
Can you help please?
Bye
Herc.
up
I'm still searching

[Q] Modifying files with apkmanager

Hi all,
Apologies if this has been covered elsewhere but searching has done me no good.
I'm trying to do a bit of theming by modifying framework-res.apk with apkmanager 4.9. As I understand it, you're supposed to:
1. Decompile (9) the APK
2. Modify files in .\projects\framework-res.apk
3. Compile (11)
4. Answer Yes to this being a system apk
5. Answer Yes to keeping unmodified files
6. Delete the files from keep that have been modified
7. Press a key to continue
At this point, if I rename the new apk to file to .zip and look inside the files I've deleted from keep are simply not there.
If I don't delete the files from keep, the old files are there, not the new files I'm replaced them with.
If I replace the files in keep with the modified versions again instead of deleting them, they do appear in the final apk and show up on my phone correctly. This only work for images though and this isn't working for XML files - only images.
After step 5 I get a line in the apk manager log saying "The system cannot find the file specified."
Can someone tell me what I'm doing wrong?
Thanks

how to change app version name in AndroidManifest.xml

hi all
I want to change versionName but after recompile the app don't show in the phone ,and if I don't rename it work . Why ???
android:versionName="7.9.A.0.1_sinhhoa"
to android:versionName="7.9.A.0.1"
thanks
P/S : after many tried I had found the problem apk wasn't sign properly . I always copy META-INF folder from original apk to modded apk so it won't work.
The signature is somehow linked to manifest more than to the apk itself. If you change anything in apk except manifest, you cannot install it either way, except as system app. But if you change something in manifest, you cannot install it even as system app.
You can disable signature check or resign the rom or some system apps can be signed with different signature.

[MOD] Multi DPI Camera and Samsung Keyboard

Decided to start a new thread as this one was getting a bit messy (and I couldn't change the title anymore)
http://forum.xda-developers.com/galaxy-s6/themes-apps/mod-multi-dpi-samsung-apps-camera-t3141148
----------------------------------------------------------
Hi all, after changing the dpi to 480 the camera was the main thing bugging me. Looking for a solution I found this thread:
http://forum.xda-developers.com/galaxy-s6/themes-apps/mod-fix-samsung-camera-app-device-dpi-t3131995
But that did not work for me, so I decided to try it myself and I finally managed to create multi-dpi versions of the Camera and Samsung Keyboard apps. They are based on the apks from the XtreStoLite Universal Deo-Mod Edition 1.5 as I'm currently running that. So just give it a try (backup the original apks first! I usually just rename them to "filename.org") and let me know if it works for you. I tested on 480 and 520 dpi and that works here...
Installation:
1. Backup original apk (in system\app\SamsungCamera4 and/or systemm\app\SamsungIMEv2 )
2. Extract modded apk to the corresponding folder
3. Wipe data for the app
4. Reboot
I basically modified the dimens.xml file to hardcoded pixel sizes instead of dip value, modifying dip value caused other issues for me (camcorder not working, pro mode messing up). Hopefully it's of use to some.
I have not been able to fix the Contacts/Dialer (SecContacts_L.apk in the priv-app folder)! I either get a corrupt apk (parsing error) or it just won't show up in my apps. Corrupted apk gives a parsing error when trying to install manually, otherwise it just says 'install failed'.
I am guessing this is somethiong with the priv-app folder and other restrictions there. I also tried copying the apk to the system\app folder instead but that didn't work either...
If anyone has ANY idea how to fix this? (I tried with both apktool as apk multitool).
*SCRIPTS ADDED*
Added the scripts and all I've written for this to this post for those wanting to try themselves (dpi_mod.zip). They are not completely polished so need some manual editing every now and then...
Basically, doubleclicking apk_process.bat in the root will go through the apk's in the apk subfolder and
1. Decompile them to the decompiled subfolder
2. Edit the dimens.xml file in the res\values subfolder of the decompiled folder replacing all the <n>dip values with <4*n>px (So 640 dip becomes 2560px for example...)
3. Rebuild the apk to the dpimod_apk subfolder (using the -c option to keep original manifest and signature files)
The files folder contains the files used (apktool, the subscripts for each step, signature files, (g)awk and an awk script to process the xml file replacing the values, etc)
There is also a script for signing the apk manually, but somehow the apk then also doesn;t work in my case it seems...
ALl scripts are windows batch files (and an awk file) as I mainly use windows at home. Shouldn't be too hard for the linux users to convert them to bash files if desired...
*EDIT2*
Added patched services.jar (and original services.jar for restoration in case of issues). Flash through twrp recovery... This allows you to use the modded SecContacts_L.apk supplied, the services.jar needs to be patched to disable the signature verification for the (system) apk files. Note that this might cause issues (an invalid services.jar caused my phone to get stuck in boot... had to restore the original to be able to continue) so use at your own risk!
Great job !
I have not been able to decompile the contacts.apk either.. I am a bit rusty tho.. will have to look into that a little more.
fOmey said:
Great job !
I have not been able to decompile the contacts.apk either.. I am a bit rusty tho.. will have to look into that a little more.
Click to expand...
Click to collapse
Thanks! And yeah, weird stuff.
I actually was only really bothered by the camera, not using the samsung keyboard at all myself and don't mind the contacts as much (perfectly usable for me) but it's now a matter of principle If you find anything out, I would love to hear.
dagrim1 said:
Thanks! And yeah, weird stuff.
I actually was only really bothered by the camera, not using the samsung keyboard at all myself and don't mind the contacts as much (perfectly usable for me) but it's now a matter of principle If you find anything out, I would love to hear.
Click to expand...
Click to collapse
But In Call screen looks weird with 480 DPI right? Would you know any fix for that? Thanks.
Sent from my SM-G925F using XDA Free mobile app
ksekhar said:
But In Call screen looks weird with 480 DPI right? Would you know any fix for that? Thanks.
Sent from my SM-G925F using XDA Free mobile app
Click to expand...
Click to collapse
Yup, it does. (But again, doesn't bother me as much as I don't look at it long because I usually hold my phone to my ear anyway ).
But yeah, I think I know where to fix it... It's the Contacts apk I mentioned above but there is an issue with decompiling/rebuilding it so can't fix it yet. Looking into it.
Did notice when decompiling and recompiling including resources it fails, when keeping resources intact it does work.
To successfully mod seccontacts you have to do these steps :
- Decompile apk
- Edit xml files in res folder
- Recompile apk
- Extract xml edited files in res folder from recompiled apk
- Paste these xml files in the original apk in the res folder with compression tool like Winrar
It works I made this with my S5.
Meh, been looking into it some more and also found this:
http://forum.xda-developers.com/android/software-hacking/how-to-recompile-tw-contacts-phone-t3066350
and
http://www.ez-pg.com/guide-how-to-decompilerecompile-lollipop-seccontacts.html
I tried modifying the manifest as instructed, but the apk still didn't work. Perhaps because signature verfication is not properly disabled on my rom. BUt if it isn't it is also not for the majority of the users in which case siumply supplying the apk wouldn't work anyway.
I also tried resigning the apk, no luck. Copying the original manifast is also not going to work afaik with a changed manifest file...
More info about signature verficiation:
http://forum.xda-developers.com/showthread.php?t=2725233
http://forum.xda-developers.com/showthread.php?t=2342262
Perhaps I will try this soon as well, but for now I think I'll leave it be...
sebdigital said:
To successfully mod seccontacts you have to do these steps :
- Decompile apk
- Edit xml files in res folder
- Recompile apk
- Extract xml edited files in res folder from recompiled apk
- Paste these xml files in the original apk in the res folder with compression tool like Winrar
It works I made this with my S5.
Click to expand...
Click to collapse
Thanks for the tip, had looked into that as well but this xml file is in the values folder which is not simply found in the res folder of the apk but compiled into the resources.arsc file in the apk so this is not working unfortunately.
dagrim1 said:
Thanks for the tip, had looked into that as well but this xml file is in the values folder which is not simply found in the res folder of the apk but compiled into the resources.arsc file in the apk so this is not working unfortunately.
Click to expand...
Click to collapse
I'm on 5.1.1 today and noticed that contacts/dialer is (almost) multi DPI already without having to do anything. And your camera mod works on 5.1.1 too!
Sent from my SM-G920F using XDA Free mobile app
can u change this Camera 480 dpi camera s6 to 420 dpi?
https://mega.nz/#!M4Ui0KoR!TKsPKkMl-XQHyiJ_DNf53eQCGZTrYWhuHaAnhAYXeSM
thanks you very much
can be used for other than s6 for SamsungCamera4. ??
my android device A8 6
dagrim1 said:
Decided to start a new thread as this one was getting a bit messy (and I couldn't change the title anymore)
http://forum.xda-developers.com/galaxy-s6/themes-apps/mod-multi-dpi-samsung-apps-camera-t3141148
----------------------------------------------------------
Hi all, after changing the dpi to 480 the camera was the main thing bugging me. Looking for a solution I found this thread:
http://forum.xda-developers.com/galaxy-s6/themes-apps/mod-fix-samsung-camera-app-device-dpi-t3131995
But that did not work for me, so I decided to try it myself and I finally managed to create multi-dpi versions of the Camera and Samsung Keyboard apps. They are based on the apks from the XtreStoLite Universal Deo-Mod Edition 1.5 as I'm currently running that. So just give it a try (backup the original apks first! I usually just rename them to "filename.org") and let me know if it works for you. I tested on 480 and 520 dpi and that works here...
Installation:
1. Backup original apk (in system\app\SamsungCamera4 and/or systemm\app\SamsungIMEv2 )
2. Extract modded apk to the corresponding folder
3. Wipe data for the app
4. Reboot
I basically modified the dimens.xml file to hardcoded pixel sizes instead of dip value, modifying dip value caused other issues for me (camcorder not working, pro mode messing up). Hopefully it's of use to some.
I have not been able to fix the Contacts/Dialer (SecContacts_L.apk in the priv-app folder)! I either get a corrupt apk (parsing error) or it just won't show up in my apps. Corrupted apk gives a parsing error when trying to install manually, otherwise it just says 'install failed'.
I am guessing this is somethiong with the priv-app folder and other restrictions there. I also tried copying the apk to the system\app folder instead but that didn't work either...
If anyone has ANY idea how to fix this? (I tried with both apktool as apk multitool).
*SCRIPTS ADDED*
Added the scripts and all I've written for this to this post for those wanting to try themselves (dpi_mod.zip). They are not completely polished so need some manual editing every now and then...
Basically, doubleclicking apk_process.bat in the root will go through the apk's in the apk subfolder and
1. Decompile them to the decompiled subfolder
2. Edit the dimens.xml file in the res\values subfolder of the decompiled folder replacing all the <n>dip values with <4*n>px (So 640 dip becomes 2560px for example...)
3. Rebuild the apk to the dpimod_apk subfolder (using the -c option to keep original manifest and signature files)
The files folder contains the files used (apktool, the subscripts for each step, signature files, (g)awk and an awk script to process the xml file replacing the values, etc)
There is also a script for signing the apk manually, but somehow the apk then also doesn;t work in my case it seems...
ALl scripts are windows batch files (and an awk file) as I mainly use windows at home. Shouldn't be too hard for the linux users to convert them to bash files if desired...
*EDIT2*
Added patched services.jar (and original services.jar for restoration in case of issues). Flash through twrp recovery... This allows you to use the modded SecContacts_L.apk supplied, the services.jar needs to be patched to disable the signature verification for the (system) apk files. Note that this might cause issues (an invalid services.jar caused my phone to get stuck in boot... had to restore the original to be able to continue) so use at your own risk!
Click to expand...
Click to collapse
how to fix on parse error, after recompile SamsungCamera4.apk with apktool
with or without edit error on parse...
My device Galaxy-A8

[MOD][TEMPLATE] APK-Patcher Lite

APK-Patcher Lite
Flashable Zip Template for Modifying System APKs On-Device
Based on APK-Patcher by @osm0sis​
Information
This is a modified version of APK-Patcher that will delete / inject files into System APK files instead of using a baksmali / apktool method.
The method used here is a similar method used in my ROMs to patch files, where instead of having to have like for example 4 SystemUI files, I only needed to keep the actual files that were changed.
This method could also be used quite easily to apply OTA updates or addons on already pre-modified APK files.
LINK TO GITHUB (STANDARD): https://github.com/djb77/APK-Patcher-Lite
LINK TO GITHUB (MAGISK): https://github.com/djb77/APK-Patcher-Lite_Magisk
Usage
Copy your pre-compiled resource files (including .dex files) to the patch folder, removing the .apk part of the filename (ie: SystemUI)
Create a file in scripts with the same name (ie: SystemUI.sh) if you want to delete any existing files from the APK
Make edits to envvar.sh, and also to extracmd.sh if needed
Properties / Variables (envvar.sh)
banner="";
apklist="";
apkbak=/data/media/0/APK-Backup;
backup=1;
cleanup=1;
banner is the name of your patch zip, usually suggestive of what it does, to be displayed at the beginning of the zip flash. You should include your name/handle here like "by osm0sis @ xda-developers" for credit purposes.
apklist is a string containing the list of APKs to be patched included in the patch zip, separated by spaces between the quotes. Each APK is automatically found recursively in /system, then copied to the working directory to be decompiled and acted on, then copied back to /system.
apkbak is the location to place backups of the untouched APKs in apklist if backup=1 is set.
backup=1 will store backups of the untouched APKs in the location specified in apkbak.
cleanup=0 will keep the zip from removing it's working directory in /tmp/apkpatcher - this can be useful if trying to debug in adb shell whether the patches worked correctly. cleanup=1 is necessary on multi-APK patching zips, so it's recommended each APK to be patched be tested on their own with cleanup=0 before combining into a single zip.
envvar.sh
Modify the envvar.sh to add your banner, apklist, backup and cleanup options
Multiple files can be patched, put a space between the filenames (ie: apklist="file1.apk file2.apk"
extracmd.sh
Modify the extracmd.sh to add any additional commands to be performed at the end of the patching process that aren't patch-related (/data file changes,
scripts/$apkname.sh
fileremove="";
$apkname is the name of the folder that you put your resources files in. Copy scripts_sample.sh and rename it to your APK (ie: SystemUI.sh)
Multiple files can be deleted, put a space between the paths (ie: fileremove="/res/drawable/file1.png /res/drawable/file1.png"
For me returned error bellow
Code:
local entry crc does not match

Categories

Resources