Introduction
Google has updated Android System Webview for Lollipop, but is only exclusive for stock Nexus ROMs. The app is available in Play Store but renders unusable for non-Nexus ROMs. The 'framework-res.apk' contains a string that links the webview to the stock package 'com.android.webview,' and the updated webview uses the package name 'com.google.android.webview.' This mod replaces the link for the Webview from stock to the updated package.
An Xposed module is available but Xposed Framework is in its 'Super Alpha' stage for Android 5.1.1. This mod is for those who don't want to test an unstable build yet.
Instructions
NOTE: Ensure that a backup is available in case things get out of hand.
Download and install Android System Webview from Play Store or replace the stock webview with Delta GApps Webview Addon (flash).
Download the attached file and place it in the device's storage.
Flash the downloaded file through recovery.
Reboot the system.
DIY Tutorial
If you have other mods installed, you can apply this mod alongside them.
Requirements
Windows Platform
A PC
Modified framework-res.apk
Instructions
Go to iBotPeaches' Apktool website and follow the installation instructions for Apktool 2.x.
Place the modified framework-res.apk together with the previously downloaded files in the same folder.
Hold 'Ctrl' + 'Shift' and right-click inside the folder and select 'Open command window here'.
Type in:
Code:
apktool if framework-res.apk
This imports the framework, which is what the 'if' stands for.
Type in:
Code:
apktool d framework-res.apk -s
This decodes the apk. The '-s' variable makes it decode only the resources, which saves us more time in decompiling.
Navigate to 'framework-res\res\values'.
Open up strings.xml and find 'config_webViewPackageName'.
Replace 'com.android.webview' with 'com.google.android.webview' and save.
Type in:
Code:
apktool b framework-res -c
This rebuilds the apk, which is what the 'b' stands for. The variable '-c' copies the original AndroidManifest.xml and META-INF folder. These contain the signatures of the apk and are necessary to function properly.
The recompiled framework-res.apk will be placed in 'framework-res\dist'.
Overwrite the existing framework-res.apk manually or replace the one in the flashable zip with the newly modified framework-res.apk.
thanks for your guide bro
will try this soon, but what we know how this work, if we success install this mod?
Nicklas Van Dam said:
thanks for your guide bro
will try this soon, but what we know how this work, if we success install this mod?
Click to expand...
Click to collapse
The only way I found out it was working was when I removed/replaced the stock webview, Google apps didn't force close at boot. I haven't thought/found other ways on how to.
elmkzgirxp said:
The only way I found out it was working was when I removed/replaced the stock webview, Google apps didn't force close at boot. I haven't thought/found other ways on how to.
Click to expand...
Click to collapse
So I must deleted stock android web view?
Nicklas Van Dam said:
So I must deleted stock android web view?
Click to expand...
Click to collapse
It's not necessary as it is guaranteed to work. But if you really wanted to make sure, then you can go ahead and replace/remove the stock webview.
elmkzgirxp said:
It's not necessary as it is guaranteed to work. But if you really wanted to make sure, then you can go ahead and replace/remove the stock webview.
Click to expand...
Click to collapse
is this will make bootloop? i used cm and this very fragile for that thing
Nicklas Van Dam said:
is this will make bootloop? i used cm and this very fragile for that thing
Click to expand...
Click to collapse
No. You should consider the risk when dealing with these things. Otherwise don't attempt to do such modifications.
elmkzgirxp said:
No. You should consider the risk when dealing with these things. Otherwise don't attempt to do such modifications.
Click to expand...
Click to collapse
i'm not consider that -_-, but i'm very lazy to reflash again if this bootloop. ok thanks for suggest
i've do patch to core.jar from lucky patcher. that's why i lazy with that thing -_- . if reflash it take much time to patch it again
@elmkzgirxp
is there way to check if webview is working??
also there are three files related to webview in aosp ROMs at /system/lib folder
1)libwebviewchromium.so
2)libwebviewchromium_loader.so
3)libwebviewchromium_plat_support.so
do they need replacement as Google webview also has libwebviewchromium.so file
mepsilon2 said:
@elmkzgirxp
is there way to check if webview is working??
also there are three files related to webview in aosp ROMs at /system/lib folder
1)libwebviewchromium.so
2)libwebviewchromium_loader.so
3)libwebviewchromium_plat_support.so
do they need replacement as Google webview also has libwebviewchromium.so file
Click to expand...
Click to collapse
The only way I know is that it doesn't return error messages on certain apps in logcat.
If you're talking about AOSP, the three libraries are used by webview.apk, the stock one. If you are using 5.0+, then it's not necessary to remove them, as the libraries in the /system/app folder takes precedence. But if you're using 4.0+, then you have to replace them. Most flashable zips do this work for you, unless you're doing it manually.
elmkzgirxp said:
The only way I know is that it doesn't return error messages on certain apps in logcat.
If you're talking about AOSP, the three libraries are used by webview.apk, the stock one. If you are using 5.0+, then it's not necessary to remove them, as the libraries in the /system/app folder takes precedence. But if you're using 4.0+, then you have to replace them. Most flashable zips do this work for you, unless you're doing it manually.
Click to expand...
Click to collapse
thanks
I'm on 5.1.1. Google webview has it's own libwebviewchromium.so shouldn't it have it's own libwebviewchromium_plat_support.so and libwebviewchromium_loader.so also??
---------- Post added at 10:42 AM ---------- Previous post was at 10:28 AM ----------
I guess it shouldn't as stock webview also has only libwebviewchromium.so Other 2 lib files must be common for both webview
mepsilon2 said:
I guess it shouldn't as stock webview also has only libwebviewchromium.so Other 2 lib films must be common for both webview
Click to expand...
Click to collapse
Right, of course, I forgot. The other two libraries are still necessary for it to function, but they rely on different libwebviewchromium.so.
elmkzgirxp said:
Right, of course, I forgot. The other two libraries are still necessary for it to function, but they rely on different libwebviewchromium.so.
Click to expand...
Click to collapse
I don't know if people already know this or not. but There is now no need to compile and decompile framework. there is a new commit which support both type of webview. Here is link for SlimRom
https://github.com/SlimRoms/frameworks_base/commit/72556d08c5a50d01252c74e1cec361ee24edd6e6
This support I have found in CM and AICP ROM too but not in ParanoidAandroid
mepsilon2 said:
I don't know if people already know this or not. but There is now no need to compile and decompile framework. there is a new commit which support both type of webview. Here is link for SlimRom
https://github.com/SlimRoms/frameworks_base/commit/72556d08c5a50d01252c74e1cec361ee24edd6e6
This support I have found in CM and AICP ROM too but not in ParanoidAandroid
Click to expand...
Click to collapse
Yeah, this thread is actually outdated, but I am unable to delete it. This could just be for future reference.
Related
http://evervolv.turnertechrepair.info/Clark44/Android4.0-System-Dump.zip
Courtesy of Jrbourque
EDIT: Thanks Efrant, Title changed.
EDITED WITH ALTERNATE LINK
link didnt work for me
The correct link http://evervolv.turnertechrepair.info/Clark44/Android4.0-System-Dump.zip
from twitter.com/#!/ts0cha0tik/status/126506123288248320 the correct download link is t.co/MagyJCbm
Thanks! Now to see what I can rip off and put on my incredible.
Is there any confirmed way to deodex the apps and framework? The latest smali/baksmali didn't work for me.
sdk dump. same as before..
Why do people keep posting SDK dumps? We all know where the SDK dump is available...
OP, please change the title to reflect that this is the SDK dump...
I just jumped into their irc channel to check if anyone had analyzed the reason for baksmali failing on the ICS odex files. It seems it was basically a function that had changed syntax, requiring several other changes but HomerSp sent me a working baksmali.jar. Smali then doesn't complain when compiling the result.
Unfortunately he went offline just after that so I'm not sure he would be ok with me posting it here so I won't. I'll write a script to deodex the files instead and upload the results if nobody else does so.
I was actually just curious about why it failed, didn't expect at working version just like that.
EDIT: Done and uploaded. Thanks again to HomerSp for the working baksmali.jar!
framework-deodexed.zip
app-deodexed.zip
NOTE: I just realized I forgot to fix the signatures so for the apps it will probably fail unless resigned. I leave that to someone else though. I have not verified that these are valid but as I said, at least smali didn't have a problem compiling them so they are hopefully ok.
blunden said:
I just jumped into their irc channel to check if anyone had analyzed the reason for baksmali failing on the ICS odex files. It seems it was basically a function that had changed syntax, requiring several other changes but HomerSp sent me a working baksmali.jar. Smali then doesn't complain when compiling the result.
Unfortunately he went offline just after that so I'm not sure he would be ok with me posting it here so I won't. I'll write a script to deodex the files instead and upload the results if nobody else does so.
I was actually just curious about why it failed, didn't expect at working version just like that.
EDIT: Done and uploaded. Thanks again to HomerSp for the working baksmali.jar!
framework-deodexed.zip
app-deodexed.zip
NOTE: I just realized I forgot to fix the signatures so for the apps it will probably fail unless resigned. I leave that to someone else though. I have not verified that these are valid but as I said, at least smali didn't have a problem compiling them so they are hopefully ok.
Click to expand...
Click to collapse
First i will like to say thanks, great work, the APKs will still not install, it keeps saying "there is a problem parsing the package." Is there any fix???
max63094 said:
First i will like to say thanks, great work, the APKs will still not install, it keeps saying "there is a problem parsing the package." Is there any fix???
Click to expand...
Click to collapse
As I said, they are not signed correctly as that would require me to remove the current signature files and resign them. I am currently sick so I didn't feel like doing it since anyone else could fix that if they wanted to.
To fix it, remove the META-INF folder from the apk and then sign it using jarsigner (part of Java JDK) or signapk. If you want to install them as normal apps you would need to make sure you pack any libs needed in the apk in a lib folder and then sign the apk using your own keystore. I mostly posted it in the hope that it would help someone make an SDK port though but use them however you like.
blunden said:
As I said, they are not signed correctly as that would require me to remove the current signature files and resign them. I am currently sick so I didn't feel like doing it since anyone else could fix that if they wanted to.
To fix it, remove the META-INF folder from the apk and then sign it using jarsigner (part of Java JDK) or signapk. If you want to install them as normal apps you would need to make sure you pack any libs needed in the apk in a lib folder and then sign the apk using your own keystore. I mostly posted it in the hope that it would help someone make an SDK port though but use them however you like.
Click to expand...
Click to collapse
Deleted META-INF, signed the launcher via Kitchen & tried to install via ADB, getting error [INSTALLED FAILED - OLDER SDK]..
Any clue?
fshami said:
Deleted META-INF, signed the launcher via Kitchen & tried to install via ADB, getting error [INSTALLED FAILED - OLDER SDK]..
Any clue?
Click to expand...
Click to collapse
Yes, you need to change the minimum SDK version in AndroidManifest.xml to Gingerbread.
Code:
<uses-sdk
android:minSdkVersion="14"
android:targetSdkVersion="14"
>
</uses-sdk>
You need to change android:minSdkVersion="14" to 9 (for 2.3-2.3.2) or 10 (for 2.3.3-2.3.7). I have a feeling it probably won't work completely as it probably uses some ICS APIs.
The problem is that apktool doesn't work since it uses the non-working baksmali. Because of that, I don't know how to convert the file back to it's binary form.
Anyone has yet installed the ICS live wallpapers?
ilbeppez said:
Anyone has yet installed the ICS live wallpapers?
Click to expand...
Click to collapse
The SDK doesn't include any live wallpapers other than a rotating wireframe cube.
So is anyone going to port the apps to gingerbread? I've seen them posted everywhere but so far no ports
Link_of_Hyrule said:
So is anyone going to port the apps to gingerbread? I've seen them posted everywhere but so far no ports
Click to expand...
Click to collapse
I have already explained just a few posts earlier why it's currently not as easy to do as it normally is.
So no one can do it because the apk tool can't recompile it properly?
Warning:
This guide isn't orginally by me, I found it on internet and posting (with some edits) here to help people
The original post : http://epiccm.blogspot.com/2012/01/porting-touchwiz-apps-for-cm7.html
Click to expand...
Click to collapse
Many stock Samsung apps are awesome and beautifully looking, also cyanogen mod is fast and high customizable, you dont need to sacrfice CM& for good looking apps anymore
Click to expand...
Click to collapse
STEPS:
1- get your desired App from System/app + twframework.jar and twframework-res.apk from System/framework
2- Decompile all of them Using APK Manager OR Apktool OR Virtous Ten Studio or any other apps
Guide for decompile,compile : HERE
Click to expand...
Click to collapse
3- Remove the library dependence from the AndroidManifest.xml
The line looks like this:
Code:
and remove any lines contain ‘com.device.samsung’
This to make it install on non samsung roms
Click to expand...
Click to collapse
4- Copy the twframework code into the app source.
‘twframework.jar.out/smali/’
The app now contains both its own code, and all the needed TouchWiz code. There’s a small chance it might work if you recompile it now, but it probably also needs resources
Click to expand...
Click to collapse
.
5-Update the resources
a. Add the needed files/parts
search for any ‘@touchwiz:’ parts in any xml file under res/.
Next, you will need to merge everything under /res/ from the twframework-res.apk.
Copy over anything that doesn’t already exist. Files under /res/values/ (Except public.xml) will need to be merged, meaning insert all the values from the framework into the app, before the closing tag (Keep the XML valid). If your missing any resources, re-compiling the APK will fail
b. Remove the touchwiz references
Replace every ‘@touchwiz:’ with just an ‘@’
Example :
Code:
@touchwiz:color/
to
@color/
Copied directly from OP :
There are some calls to IDs in the 0x20 range, this is an issue because as far as I know, the 0x20 range can only be provided by the system somehow. For the Calendar app, I had to remove setIcon calls in a few activities to prevent ResourceNotFound exceptions.
If you remove them, then some things like images might not work. I also found that just removing them can cause random NullPointer errors.
Note: While working on the Task Manager, it became more complex. I had to update the old 0x20 references to the references within the new package.
After the resources are added, decompile it again, so the added resources show up in the /res/values/public.xml
Search for the old 0x20 value, and update it to the new value. If you include the /smali/touchwiz/ directory, then you can just search for the hex value and you will get the name of it from the TW R.smali files, and you can find the updated hex value in the /res/value/public.xml file
Click to expand...
Click to collapse
6. Re-compile
7. Sign the apk using platform key or testkey from HERE
GUIDE TO SIGN APK
Click to expand...
Click to collapse
Most apps uses testkey but if you had any permission error, use platform key or search google for the error
Click to expand...
Click to collapse
8. Install
adb push /system/app/
OR
using system app installer
OR
using any root explorer
Credits :
-Original poster
-Me, for simplifing it
Click to expand...
Click to collapse
Well this is useful!
I Will release some apps, after my exams finish
Sent from my GT-S5360 using Tapatalk 2
Is it possible to port stock fm radio to cm7?
bluestarfish said:
Is it possible to port stock fm radio to cm7?
Click to expand...
Click to collapse
you can try it, but it will not work anyway. there is a radio fm bug in cm7
yeah finaly i got this
many thanks sir
Well, I had it in my mind everytime but never tried doing it... #laziness
Anyways, this IS usefull :good:
Nachiket.Namjoshi said:
Well, I had it in my mind everytime but never tried doing it... #laziness
Anyways, this IS usefull :good:
Click to expand...
Click to collapse
Its a great honor for me that a good developer like you admires my work
On a side note : many devs ported stock apps (generally clock widget and launcher and task manager) to CM7 but no one ever shared, I don't like those who don't share their experiences
Sent from my GT-S5360 using Tapatalk 2
Perfect !
Just what i needed good job OP
Here is the way to sign your apk with system platform...
Jar modification bye bye for Cyanogen Users... Hahahaha...
Method
1) Unzip and put apk were data uncompressed...
2) rename it to k.apk
3) and run script...
Password :android
zip Attached
enjoy... signed apk only for CM12 and CM12.1.1 , my AOSP uses Cm12.1.1 platformkeys
so it work on rom that build with cm12 or cm12.1.1 keys
reserved
Why it's protected with a password ?
Plus, it's should be posted on Android Themes/General forums not Xperia specif forums.
I used ZipSigner.apk for that
wolfmannight said:
Here is the way to sign your apk with system platform...
Jar modification bye bye for Cyanogen Users... Hahahaha...
Unzip
and put apk were data uncompressed...
rename it to k.apk
and run script...
Password :android
zip Attached
enjoy... signed apk only for CM12 and CM12.1.1 , my AOSP uses Cm12.1.1 platformkeys
so it work on rom that build with cm12 or cm12.1.1 keys
Click to expand...
Click to collapse
It mean i can make superuser mod with this?
Sent from my Xperia L using Tapatalk
it will enable SU for that signed apk
for many apk you need to sign every apk by this
After this do we need superuser mod. And just by that can we install any app on any phone
khurshid_258 said:
After this do we need superuser mod. And just by that can we install any app on any phone
Click to expand...
Click to collapse
any apk with any cm12 or cm12.1 based rom
abo hani said:
Why it's protected with a password ?
Plus, it's should be posted on Android Themes/General forums not Xperia specif forums.
Click to expand...
Click to collapse
Sir,
signing apk can done without password with keystore ? I don't think so..
I not put password , its a basic manual method to sign apk with platform keys
(keystore)A Java KeyStore (JKS) is a repository of security certificates – either authorization certificates or public key certificates – used for instance in SSL encryption.
I thought , 70% of Xperia apk works by signing them with Platform key ... So I posted
and I never open xda's other forms
I only open Sony Cross-Device General and Sony Cross-Device Development Themes and Apps , hahahaha
darknessmc said:
I used ZipSigner.apk for that
Click to expand...
Click to collapse
ZipSigner.apk is phone based I also have apksign.apk , but my phone take too much time to sign 14 Megabyte file , my phone is too slow
so i used to be sign apk on my mac
Nice tutorial, but I'll stick with replacing the testkeys in Apktool with the custom ones I currently need.
Just keep in mind that apps signed with platform keys cannot be installed normally. They gotta be pushed directly to system to work.
Just mentioning.
WhiteNeo said:
Nice tutorial, but I'll stick with replacing the testkeys in Apktool with the custom ones I currently need.
Just keep in mind that apps signed with platform keys cannot be installed normally. They gotta be pushed directly to system to work.
Just mentioning.
Click to expand...
Click to collapse
yup bro.
I can't do it . whenever I run the script it show some file not found error in command prompt , and my file get deleted
khurshid_258 said:
I can't do it . whenever I run the script it show some file not found error in command prompt , and my file get deleted
Click to expand...
Click to collapse
before run rename your xxxx.apk to k.apk
then run script
wolfmannight said:
before run rename your xxxx.apk to k.apk
then run script
Click to expand...
Click to collapse
I am doing like that only then also that error is coming. I have attached the image of the error
khurshid_258 said:
I am doing like that only then also that error is coming. I have attached the image of the error
Click to expand...
Click to collapse
Make sure you have jdk installed first.
If so then make sure you use the right path for it, maybe you have different version of jdk installed. As for me my jdk bin folder as follows:
"C:\Program Files\Java\jdk1.8.0_60\bin"
because I have jdk version 1.8.0_60 installed.
Hi,
i have themed/edited Settings.apk, then i recompiled/signed/zipaligned without warnings with ApkTool, but once overwritten original Settings.apk and chmoded to 0644 i can't restart the phone, it is stuck on "Android starting" or "updating" (i can't remember the correct text showing). Now i resored the original Settings.apk and all is working fine.
Am i missing something? I have used framework-res and framework-res-htc.
I'm on rooted stock rom latest firmware, no xposed.
Thanks and sorry for my bad english.
which version of apktool?
you need to manually resign the rebuild apk in newer apktool versions
In order to run a rebuilt application. You must resign the application. Android documentation can help with this.
Click to expand...
Click to collapse
and why the double post?
peteter said:
which version of apktool?
you need to manually resign the rebuild apk in newer apktool versions
and why the double post?
Click to expand...
Click to collapse
I'm using "Advanced ApkTool v4.2.0", apktool.jar is a compatible version for marshmallow but i don't remember the version number, previously i themed various xperia themes for marshmallow without issues.
What do you mean with "you need to manually resign the rebuild apk in newer apktool versions"? Like i said i'm using Advanced ApkToo and it has sign command.
Double post is an error, i have requested the deletion.
Thank you
ah ok, thought you were using the standalone apktool from ibotpeaches, there you have to resign the rebuild apk yourself.
just check the link in the quote
[DISCLAIM]
Doing at your own risk, I don't hold any responsibility for any consequence that may have occured.
I personally have tested this mod on my rooted pixel on NOF26v release.
Remember to do a backup first.
I personally recommended to overwrite those files and keep your adb connected and restart the system ui instead of a directly rebooting by install the app. . By this way, if there is something wrong, you could easily revert the change via adb.
[Background]
After a week, accompanied with many bootloop and systemui FCs, I finally managed to make the real network traffic to show in the status bar.
I was inspired by this post post by @Morningstar, however, the code is outdated and does not work with the latest nougat release.
I then extracted all the updated smali files from Resurrect Remix ,specifically the system image for flo device because I personally owned a nexus7 2013.
I modified the scripts provided by @sellsky, actually a lot of changes needs to be done, and you need to add missing code when you see something unusual in 'adb logcat'.
You can find the modded files (SytemUIGoogle.apk, SettingsGoogle.apk ) from here.
You can find the modded trafficcm from here.
Screenshot is also attached.
Updated files for NOF27B: https://drive.google.com/file/d/0Bzu0Zqno-_D7ZzFOckhHSHRZeGc/view?usp=sharing
Updated files for N2G47E : https://drive.google.com/file/d/0Bzu0Zqno-_D7ejRYZU9UeFljTFE/view?usp=sharing
Updated trafficcm script for 7.1.2: https://drive.google.com/file/d/0Bzu0Zqno-_D7a3F6aTU2MDVrdFU/view?usp=sharing
Nicely done.
Great job .
Bro can you give me some instructions so that I can mod on my stock OnePlus 3 rom
Hi,
I would like to ask how apply this mod. Must I copy SettingGoogle.apk and SystemUIGoogle.apk from traffic_mod.tar? Where can I find this *.apk in system.
Thank you very much for your help
kevin.kvik said:
Hi,
I would like to ask how apply this mod. Must I copy SettingGoogle.apk and SystemUIGoogle.apk from traffic_mod.tar? Where can I find this *.apk in system.
Thank you very much for your help
Click to expand...
Click to collapse
They are both in system/priv-app in their own folders.
Tulsadiver said:
They are both in system/priv-app in their own folders.
Click to expand...
Click to collapse
I don´t have this folders in system/priv-app
kevin.kvik said:
I don´t have this folders in system/priv-app
Click to expand...
Click to collapse
Then you don't have a Pixel?
works perfectly, I copied both files to system/priv-app, reboot, magic. Thank you!
This one feature is ~70% of my love for xposed. Thanks for porting this over... greatly appreciate it.
To be clear for others, the script is not required for this to work.
Back up the two files in question, both in system/priv -- then copy the above apks into the respective folders and reboot.
After installing this mod and you want it on the left hand side, flash this.
If someone who is using a OnePlus 3/T is able to make this work please say how you did it because I can't find the files that need replacing on my device.
have no idea on how to use the modification and will this still work on latest security patch
bush911 said:
have no idea on how to use the modification and will this still work on latest security patch
Click to expand...
Click to collapse
Works fine.
The thread has been quite clear.
1.) Download
2.) Copy
3.) Reboot
4.) Enable
bush911 said:
have no idea on how to use the modification and will this still work on latest security patch
Click to expand...
Click to collapse
Should work fine, and you could also try the newest build I made ( I have updated the main OP ).
Scarface1991 said:
If someone who is using a OnePlus 3/T is able to make this work please say how you did it because I can't find the files that need replacing on my device.
Click to expand...
Click to collapse
Are you deodexed?
Tulsadiver said:
Are you deodexed?
Click to expand...
Click to collapse
I'm using a custom ROM that is based on AOSP so I think I am. At least there are no .odex files within my system/app folder.
Scarface1991 said:
I'm using a custom ROM that is based on AOSP so I think I am. At least there are no .odex files within my system/app folder.
Click to expand...
Click to collapse
Upload your systemui.apk, framework-res.apk, and settings.apk or whatever yours is called.
I'm not a pixel user, using clean AOSP on Redmi note 3 snapdragon. Can I use these modded files? Or they are SoC dependent?
I'm pretty much a noob ?
kurogami95 said:
I'm not a pixel user, using clean AOSP on Redmi note 3 snapdragon. Can I use these modded files? Or they are SoC dependent?
I'm pretty much a noob
Click to expand...
Click to collapse
You can't use the finished product but using the script might work if you will change the names of your settings.apk and systemui.apk to match the pixel and run his script on your pc. Afterwards change the names back.
Ops updated for android 7.1.2, there are some change in the android support lib.