[Oreo] How to integrate apps update in rom. - Android Q&A, Help & Troubleshooting

After update my LG G6 (LG-H870) from nougat to oreo, I've have problem with integration updated apps in to /system.
I do it like this:
1. copy apk file from data/apk to sd card
2. rename copied apk file to name of /system apk
3. extract lib folder from apk
4. copy newer file to proper folder in /system/app or /system/priv-app and replace file in it
5. Copy lib files extracted form apk to right folder /system/lib or /system/lib64
6. Uninstall update from /data/app
7. reboot + dalvik-cache wipe
In nougat it was working, but in oreo, app after integration, breaks. It cannot be open, and app name changes to random words (ex. google docs name changes to "write com.android").
To repair integrated apps I have to perform a full /data/ wipe.
Is it a some kind of protection? How to do it properly?
TitaniumBackup and Link2SD cannot integrate updates to rom properly without errors since Lolipop.

Related

[Q] Choose Specific App Install Path

Hi
I'm trying to move my security software apk file to the /system/app folder to make it hard reset proof. I renamed the original apk which is in the /data/app folder. I then copied the file to the /system/app folder and renamed it to the original filename. I then installed the apk, chose replace. What happend was that the app created another apk in the /data/app folder this time with a "2" behind it.
I'm guessing the apk has code in it that tells it to install there. So what I was wondering, can I set a specific default install directory, install the apk and then return it to default?
or
Where do the file go after the apk is ran, the program isn't ran by the apk because when you try and run it, it just asks to install it, not open the program. Could I move the actual app files and edit the install path in where the os stores the list of installed apps and there paths (where ever that is?)?.

Viper4Android (SOFF WORKAROUND)

I have successfully created my own bypass to get viper4android to work. Always create a full backup before attempting =)
1. Download viper4android APK
2. Download Root Explorer from the playstore
3. Install Both Apps
4. Launch Root Explorer
5. In root explorer go to /system/lib/soundfx and copy the folder to /data/ (make a soundfx folder)
6. Also copy /system/etc/audio_effects.conf to the /data/soundfx/ folder
7. Using root explorers menu you can create a shortcut (symbolic link) make a shortcut of the /data/soundfx/ folder and a shortcut of the /data/soundfx/audio_effects.conf
8. Boot into TWRP
9.Mount the system partition
10. Rename /system/lib/soundfx to /system/lib/soundfx2
11. Copy soundfx shortcut create earlier to /system/lib/ it will look like a "file" to TWRP
12.Rename the /system/etc/audio_effects.conf to /system/etc/audio_effects.conf1
13. Copy the audio_effects shortcut into /system/etc/ (be sure its name matches the old exactly)
15. Reboot
16. Launch Viper and install driver
I haven't dealt with LPA yet (hasn't had an issue) nor have I done any other modifications at this time which are avail on the viper4android thread.
I was just thinking about symbolic links to get around this S-OFF/ON issue and it appears they work and technically as a workaround we could symbolically link everything in system to another location and access it all. This could easily be put into ROM builds now at least as well!
Build.Prop may be useful to move out via sym link as well
I'll try this in a bit. Thanks
Sent from my HTC One_M8 using Tapatalk

[GUIDE] Integrating apps to system manually

Since PA Gapps doesn't have any more support I've been trying my self to integrate the Gapps updates into system partition, and with Android 5.x i found it's easy because in previous versions the libraries had to be integrated but they were in separate directories, now the apk and the libraries are in the same directory, so it's just question of moving the whole directory to the system partition, reboot and voiala! In my case I use Root Explorer, just use the one you want, hope this helps out the ones with the same problem and sadness of no more PA Gapps.
Here the steps:
1. Locate your user app/update at data/app
2. It should appear as com.example.app folder
3. Highlight it and select "Move"
4. Now put in system/app
5. Reboot
Note 1: At step 3 you must move the whole folder and not just the apk
Note 2: I found that some AOSP Apps are in system/priv-app, like the Keyboard, so, for avoiding troubles, if you replace an AOSP app move it to his corresponding AOSP directory
Note 3: Also, you can de-bloat your ROM by deleting Apps (whole directory) with a root explorer, if you want to find an app PM me or ask what a apk is for before deleting it
This is my first post, if I made a mistake please tell me and sorry if I have bad english.

Port a Rom the Basic way [no signing - no compiling - no special software]

Use a CM Rom for your Base as these are tried and tested (you can use Stock also as long as you are porting to another similar Stock Rom hardware)
(Make a backup copy of all the files your download - you may need to extract the files again later)
: : : You will not need to re-sign your rom.zip as you will be using an existing already signed rom : : :
: : : The drag and drop method does not require you to re-sign the rom : : :
: : : You will need notepad++ (win) or TextWrangler (mac) to edit build.prop files and scripts : : :
: : : You will also need winzip7 / winRAR (win) or Springy / B1FreeArchiver (mac) to edit the rom.zip files : : :
Find your a working Base Rom for your mobile and extract the contents to your desktop, then delete the following folders from the desktop
system/app
system/fonts
system/framework
system/media
system/priv-app
Edit the build.prop file in the Base Rom >system folder to reflect your new Port Rom details - these vary depending on the port your are using
The lines you need to look for are as follows;
ro.build.id=
ro.build.display.id=
ro.build.date=
ro.modversion=
Now find the Port Rom you want to go to making sure it is close to your manufacture as possible [for example; xperia SP use xperia Z - these have similar screen sizes and hardware]
Extract the contents as before and now copy the following folders back into the Base Rom on your desktop
system/app
system/fonts
system/framework
system/media
system/priv-app
Now open the original Base Rom .zip (do not extract it) with winzip7 or winRAR and delete the following folders
system/app
system/fonts
system/framework
system/media
system/priv-app
Now with the .zip still open 'drag and drop' ALL the folders from your desktop Base Rom into the now open base Rom .zip over-writting any existing files/folders
Do not save just close the .zip and upload to your mobile sdcard, enter recovery, flash and enjoy.
Possible Issues and solutions:
You may need to remove the kernel in the Base Rom and sideload one more appropriate to your new Port Rom - flashtool is good for this
Recovery Crashes - error codes 6 or 7 are mainly caused by corrupted zips, bad partitions or poor coding in the updater-script file
Boot issues and strange video issues are mainly a cause of framework incompatibilities - try another Port Rom closer to your mobile hardware
I use this method for all my ports - the hardest part is finding a Base Rom, the next is realising the Port Rom can take hours of trials and errors
I never bother editing the framework files I just move onto finding another Port Rom closer to my Mobile Hardware
The least you mess about with the least there is to go wrong!!!
If you are very confident and can work with open .zip files on the fly you can perform all the above without the need to extract much other than the build.prop
Simply with the 'drag and drop' method between the two open .zip files
This possibly won't work for Miui as that requires a little more editing and work
: : UPDATE : :
This method can be done on either a windows or mac computer - I have successfully done it on both
Due to the latest Android 5.0 versions having extra compression this method may no longer work
In principal it could work however you will need other software to extract the compressed system files now compiled within the rom
Thanks to wine (mac) you can run this software however at this point the procedure is taking too long to complete, so I have given up!
Hope this helps someone
Extra Useful Stuff
Some Tips and tricks to get the most out of Android Rom's
Always keep an original .ftf backup ready to flash with flashtool if anything goes wrong
Adding Market place apps to a ROM
For Jelly Bean Rom place them into the following folder:
/system/etc/product/applications
-they should update as normal users apps once google play app store is run
-they will appear in the normal app folder as “downloads”
-they will also come back once a factory reset is initiated
For kitkat based Roms you will need to use the root of the Rom
/data/
However you will also need to update the update-script appropriately
Snappier mobile
go into Settings > developer options > and Window animation scale and Transition Animation scale > change both of those to 0.5x
(or 0 for both, for instant reactions).
Fix issues with no sound or muted incoming calls/text
clear data for messaging app and phone app
fix issues with rotation, excellerometer and proximity sensor
simply smack the back of the mobile firmly into the palm of your hand
fix for unresponsive or fc of google play store
Go into recovery and clear all Cache values (Partition cache and Davik cache)
reinstall Gapps and reboot
If that fails try this:
clear the data for all google apps and the following;
google account manager
google play services
google play store
google services framework
and make sure 'download manager' is enabled
Turn any nano backup into a flashable ROM
system.ext4.tar.a*– Contains the system files
data.ext4.tar.a – Contains all other data files
backup with CWM
rename system.ext4.tar.a to system.tar
extract contents and drag and drop contents into an exsiting rom.zip
Better performance
goto system/bin/ and rename mpdecision to mpdecision.old
Problems with media storage
place .nomedia file in any folder you want excluding from album app
use file manager to create the file and show hidden files to view file
(.nomedia is hidden by default) clear cache on media storage app and restart
As usual you use these at your own risk

priv-app APK modification

Hello All,
I am trying to add/edit xml files found inside "assets", "vendor" directories of an APK included in system.img (priv-app directory) 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
I have used apk tool to decompile and re-compile the apk. I also zipaligned, signed with my own key. I copied the file to priv-app directory in the phone and restarted the phone. This did not work. I did have 644 permission for apk file after replacing. Also, I did clear the dalvik cache and cache after APK replacement.
1. Do I need to change the odex or vdex files? I did not touch them since my changes were in xml files.
2. Should I sign with originally signed signature?
3. I could not see the odex and vdex file in the priv-app directory in the phone after the ROM install(when I tried to replace the APK). Why is that?
4. Should I build a rom zip file to flash(along with existing odex and vdex files) as opposed to replacing the APK in the device?
Any help?
http://www.w3.org/2001/XMLSchema
I was looking into this as well. Everything I read said you have to be registered as carrier to make modifications to carrier config.apk , unfortunately:-/ Let me know if you did find a solution, though.

Categories

Resources