Related
Note: This Guide Is Specified For Android 4.0.# ICS, but also work with GingerBread.
Before we mod our Android Device, we need to set up a modding environment right?
1. Install JDK.
Search Download and install. The installation of JDK needs JRE (Simply if Java is installed into your computer)
2. Download APK Manager for ICS here
http://db.tt/tuhzSEEl. Extract it.
3. Install framework. Copy your phone's system/framework/framework-res.apk to 'other' folder inside APKManager folder. If there are any additional framework files, copy it into the folder too. More information will be given at the buttom of thr thread. Hold the Shift Key on keyboard amd right click the "other" folder inside APKManager folder and, click "Open CMD Window here". Type:
Code:
java -jar apktool.jar if framework-res.apk
And, if any additional framework files,
Code:
java -jar apktool.jar if *.apk
Replace * by your filename.
OK, delete all the framework apks from the "other" folder.
4. Copy the apk that you want to mod.
Most probably system/framework/framework-res.apk and system/app/SystemUI.apk to "APKManager/place-apk-here-for-modding".
Then, start modding apk processes.
1.When you decompile apk (not necessary for framework-res.apk) , copy the 3 files from "APKManager/other/Original Apktool/" to "APKManager/other/" , replaces the old files.
2. Open script.bat, enter 22 to select the current project (Enter the code of the apk you want to mod then press enter!)
3.Enter 9 Enter to start decompiling process. Do not close the SCRIPT window!
4. "APKManager/projects/*.apk/" here contains the decompiled apk.
5. Do your mod.
6. When you compiling any ICS System apks(unnecessary for normal GingerBread apks), copy the 3 files from "/other/ICS Apktool/" to "/other/", replaces the old files.
6. Return to the SCRIPT window. Enter 11 enter to start compiling apk.
7. NOTE: You [mustn't] sign the apk if it is a system apk. Only sign user apks.
8. Make a flashable zip for your apk.
9. Flash via CWM. (Must with a full nandroid backup before flashing anything!)
Reserved.
Reserved.
Nice tut mate!
Right for beginners like me
Short and has a point. Very good guide. :good:
Thanks friend for this tutorial
Gustavo RD78 said:
Thanks friend for this tutorial
Click to expand...
Click to collapse
papabubadio said:
Short and has a point. Very good guide. :good:
Click to expand...
Click to collapse
M90 said:
Nice tut mate!
Right for beginners like me
Click to expand...
Click to collapse
Thank you too!
Sent from my ST25i using xda premium
dont sign ?
thanks
Thank you!!!!
Greetings.
Enviado desde mi Motorola Atrix
x-dira said:
dont sign ?
thanks
Click to expand...
Click to collapse
You don't have to sign apks if the apk is a system apk.
Sent from my ST25i using xda premium
so, can i add CRT ANIMATION using this method??
j.r.j said:
so, can i add CRT ANIMATION using this method??
Click to expand...
Click to collapse
Good guide, but I think you need to expand on the point about making a flashable zip (unless the APK Manager does this - sorry don't use Windows)
Yes,
Go framework-res.apk/res/values/bools.xml
Change the value from TRUE to FALSE in the line like...
config_animateScreenLight
Great tut brov.... +1
to sign non-system apks:-
java -jar signapk.jar certificate.pem key.pk8 your-app.apk your-app-signed.apk
Example: java -jar signapk.jar certificate.pem key.pk8 ttpod.apk ttpod-signed.apk
danist727 said:
Yes,
Go framework-res.apk/res/values/bools.xml
Change the value from TRUE to FALSE in the line like...
config_animateScreenLight
Click to expand...
Click to collapse
ok, i found framework-res.apk/res but cant find the " values/ " path..
i attached my framework-res.apk
thx for replying
真的很谢谢你:silly:
Hey Guys ,
I am writing this small guide for people who have just started off with Android Development recently..
as am not a great developer at my end so any corrections and suggestions are always welcome
Credits : To Vegeta1. He give me the idea and helped me patiently with every question i got to finish this!
To my great Omega Team Mates! You guys and girl know my feelings.
So here we gonna learn how to decompile/recompile/ sign Apks
Things needed :
1. jdk/java Get It from here--> http://www.java.com/en/
2. Apktool: Using any according to your liking is ok or you can get all the Stuff needed In this Link
http://forum.xda-developers.com/showthread.php?t=1755243
Thanks To iBotPeaches For The Superb Tool...
3. Notepad++ to make changes in Xmls
4: winrar/7zip
So first up we are gonna set up the Framework for the current Firmware we are using.
For that get framework-res.apk, twframework-res.apk from your rom. You can always find that in the root location
/system/framework/
So lets say you have placed your apktool in your C:\ drive
now open click on start > run > type cmd ( this is for command prompt )
for example you are on C:\>User. Click in the command line cd.. and hit enter.
You should see now C:\>, as next step you type cd apktool and click enter. Here you see how it should look:
C:\apktool>
Now first up installing framework-res.apk and twframework-res.apk.
Place both these Files in your apktool folder that you have placed in C Drive or any drive you are comfortable with.
Code for Installing frameworks :
C:\apktool>apktool if framework-res.apk
C:\apktool>apktool if twframework-res.apk
this will get both your frameworks installed .
Now decompiling the Apk ...
Lets say you want to decompile SecMms.apk / or any Apk you like
place the Apk in the apktool folder.
Code to decompile the apk:
C:\ apktool > apktool d SecMms.apk
If you done and set up things accordingly your Apks will be decompiled properly
in the apktool folder you have placed in C:\ apktool
you will get the decompiled SecMms folder... so you can now make changes to it
Now the Recompiling Part:
If you have made correct changes it won´t give you any issues :
To recompile the apk the code needed in the command prompt :
c:\ apktool>apktool b SecMms ( its the decompiled Folder , now the original apk )
when you are done with recompiling in the SecMms folder you will get these :
assets
build
dist
res
smali
AndroidManifest.xml
apktool.yml
Now again , if the changes you made are correct the recompiling wont give any issues
Now its still not over we need to sign the apk:
So in your apktool folder you have your Original SecMms.apk file open that with winrar/7zip
and extract
META-INF
AndroidManifest.xml
in the apktool folder and move them to
( Decompiled )SecMms > build > apk >
then again start cmd and again run the recompiling code again one more time
c:\ apktool > apktool b SecMms
this should sign your apk
and the final apk , you will find it in c:\apktool\SecMms\Dist\
.
So Guys that's about it , for decompiling/recompiling/signing your Apks , hope you have no issues and find my post helpful
Chris_84 said:
Hey Guys ,
I am writing this small guide for people who have just started off with Android Development recently..
as am not a great developer at my end so any corrections and suggestions are always welcome
Credits : To Vegeta1. He give me the idea and helped me patiently with every question i got to finish this!
To my great Omega Team Mates! You guys and girl know my feelings.
So here we gonna learn how to decompile/recompile/ sign Apks
Things needed :
1. jdk/java Get It from here--> http://www.java.com/en/
2. Apktool: Using any according to your liking is ok or you can get all the Stuff needed In this Link
http://forum.xda-developers.com/showthread.php?t=1755243
Thanks To iBotPeaches For The Superb Tool...
3. Notepad++ to make changes in Xmls
4: winrar/7zip
So first up we are gonna set up the Framework for the current Firmware we are using.
For that get framework-res.apk, twframework-res.apk from your rom. You can always find that in the root location
/system/framework/
So lets say you have placed your apktool in your C:\ drive
now open click on start > run > type cmd ( this is for command prompt )
for example you are on C:\>User. Click in the command line cd.. and hit enter.
You should see now C:\>, as next step you type cd apktool and click enter. Here you see how it should look:
C:\apktool>
Now first up installing framework-res.apk and twframework-res.apk.
Place both these Files in your apktool folder that you have placed in C Drive or any drive you are comfortable with.
Code for Installing frameworks :
C:\apktool>apktool if framework-res.apk
C:\apktool>apktool if twframework-res.apk
this will get both your frameworks installed .
Now decompiling the Apk ...
Lets say you want to decompile SecMms.apk / or any Apk you like
place the Apk in the apktool folder.
Code to decompile the apk:
C:\ apktool > apktool d SecMms.apk
If you done and set up things accordingly your Apks will be decompiled properly
in the apktool folder you have placed in C:\ apktool
you will get the decompiled SecMms folder... so you can now make changes to it
Now the Recompiling Part:
If you have made correct changes it won´t give you any issues :
To recompile the apk the code needed in the command prompt :
c:\ apktool>apktool b SecMms ( its the decompiled Folder , now the original apk )
when you are done with recompiling in the SecMms folder you will get these :
assets
build
dist
res
smali
AndroidManifest.xml
apktool.yml
Now again , if the changes you made are correct the recompiling wont give any issues
Now its still not over we need to sign the apk:
So in your apktool folder you have your Original SecMms.apk file open that with winrar/7zip
and extract
META-INF
AndroidManifest.xml
in the apktool folder and move them to
( Decompiled )SecMms > build > apk >
then again start cmd and again run the recompiling code again one more time
c:\ apktool > apktool b SecMms
this should sign your apk
and the final apk , you will find it in c:\apktool\SecMms\Dist\
.
So Guys that's about it , for decompiling/recompiling/signing your Apks , hope you have no issues and find my post helpful
Click to expand...
Click to collapse
Great guide Chris... I will try it tomorrow... Thanks for all you do for S3 and Omega community...
Ninolina said:
Great guide Chris... I will try it tomorrow... Thanks for all you do for S3 and Omega community...
Click to expand...
Click to collapse
Thanks Nina! If you got question you know where I am.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Thanks Chris84. I need this. This guide its wery good. Regards.
Wysłane z mojego GT-I9300 za pomocą Tapatalk 2
wiecho65 said:
Thanks Chris84. I need this. This guide its wery good. Regards.
Wysłane z mojego GT-I9300 za pomocą Tapatalk 2
Click to expand...
Click to collapse
Glade you like it. If you got questions just ask.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
nice one chris
bala_gamer said:
nice one chris
Click to expand...
Click to collapse
Thank you very much mate! You now it's a honor for me to get such a good feedback from you! Really appreciate that!
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Really glad to be a part of a great team and great team members ....
Good luck my friend
Sent from my GT-I9300 using Tapatalk 2
This is great, you are bringing noobs like me to the next level.
Sent from my GT-I9300 using Tapatalk 2
Chris_84 said:
Thanks Nina! If you got question you know where I am.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Click to expand...
Click to collapse
I assume it works on Windows? Maybe it will be good to add that to the Title of the Tread. Just a suggestion...
Ninolina said:
I assume it works on Windows? Maybe it will be good to add that to the Title of the Tread. Just a suggestion...
Click to expand...
Click to collapse
Yes it does. Thanks Nina for your suggestion!
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Thnx.
Always welcome a HowTo of this kind...
Verzonden door mijn GT-I9300 met xda premium
vegeta1 said:
Really glad to be a part of a great team and great team members ....
Good luck my friend
Sent from my GT-I9300 using Tapatalk 2
Click to expand...
Click to collapse
Without you my friend I never had come this far!
KeesStolk said:
This is great, you are bringing noobs like me to the next level.
Sent from my GT-I9300 using Tapatalk 2
Click to expand...
Click to collapse
So you're now a advanced noob.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Hey Chris! Really nice guide you have here, quick & simple. Decompiling worked for me, however, when I try to compile back I get this:
D:\apktool1.5.0>java -jar apktool.jar d BW.apk
I: Baksmaling...
I: Loading resource table...
I: Loaded.
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: C:\Users\MM\apktool\framework\1.apk
I: Loaded.
I: Decoding file-resources...
W: Cant find 9patch chunk in file: "drawable-hdpi/forecast_fly_child_bg_pressed.
9.png". Renaming it to *.png.
I: Decoding values */* XMLs...
I: Done.
I: Copying assets and libs...
D:\apktool1.5.0>java -jar apktool.jar b BW
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
invalid resource directory name: D:\apktool1.5.0\BW\res/drawable-land-xhdpi
invalid resource directory name: D:\apktool1.5.0\BW\res/drawable-xhdpi
invalid resource directory name: D:\apktool1.5.0\BW\res/drawable-xhdpi-v11
invalid resource directory name: D:\apktool1.5.0\BW\res/drawable-xxhdpi
invalid resource directory name: D:\apktool1.5.0\BW\res/layout-xlarge
invalid resource directory name: D:\apktool1.5.0\BW\res/layout-xlarge-land
invalid resource directory name: D:\apktool1.5.0\BW\res/values-sw600dp
invalid resource directory name: D:\apktool1.5.0\BW\res/values-w360dp
invalid resource directory name: D:\apktool1.5.0\BW\res/values-w480dp
invalid resource directory name: D:\apktool1.5.0\BW\res/values-w500dp
invalid resource directory name: D:\apktool1.5.0\BW\res/values-w600dp
invalid resource directory name: D:\apktool1.5.0\BW\res/values-xlarge
invalid resource directory name: D:\apktool1.5.0\BW\res/values-xlarge-land
Exception in thread "main" brut.androlib.AndrolibException: brut.common.BrutExce
ption: could not exec command: [aapt, p, --min-sdk-version, 8, --target-sdk-vers
ion, 17, -F, C:\Users\MM\AppData\Local\Temp\APKTOOL3965827226790767193.tmp, -I,
C:\Users\MM\apktool\framework\1.apk, -S, D:\apktool1.5.0\BW\res, -M, D:\apktool1
.5.0\BW\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:255)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:324)
at brut.androlib.Androlib.buildResources(Androlib.java:269)
at brut.androlib.Androlib.build(Androlib.java:192)
at brut.androlib.Androlib.build(Androlib.java:174)
at brut.apktool.Main.cmdBuild(Main.java:188)
at brut.apktool.Main.main(Main.java:70)
Caused by: brut.common.BrutException: could not exec command: [aapt, p, --min-sd
k-version, 8, --target-sdk-version, 17, -F, C:\Users\MM\AppData\Local\Temp\APKTO
OL3965827226790767193.tmp, -I, C:\Users\MM\apktool\framework\1.apk, -S, D:\apkto
ol1.5.0\BW\res, -M, D:\apktool1.5.0\BW\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:83)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:253)
... 6 more
Click to expand...
Click to collapse
I installed both frameworks & updated java, tried from both hdd partitions. Then I tried a different apktool version, happens again. Do you have any idea what could be the reason for this? Maybe the fact I have 2 java versions installed (v5.0 update 12 & v7 update 10).
MMWolverine said:
Hey Chris! Really nice guide you have here, quick & simple. Decompiling worked for me, however, when I try to compile back I get this:
I installed both frameworks & updated java, tried from both hdd partitions. Then I tried a different apktool version, happens again. Do you have any idea what could be the reason for this? Maybe the fact I have 2 java versions installed (v5.0 update 12 & v7 update 10).
Click to expand...
Click to collapse
I could only imagine that is not compatible this the framework you use. I get the same yesterday then I was trying recompile again Google plus. Decompile no problem but recompile give me error. Sounds a little bit crazy but what you can try is decompile with stock framework and recompile it with the one from omega or try it the other way decompile with omegas framework and recompile with stock framework. But between the steps you got install the framework new.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Thanks, I'll test it & report back.
MMWolverine said:
Thanks, I'll test it & report back.
Click to expand...
Click to collapse
Your feedback is much appreciated! Thanks my friend!
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Ok, tried with XXELL5 stock framework and tested some others as well, but no luck I'm afraid. The app is BeautifulWidgets, which I'm trying to translate into Slovenian language. The problem is I cannot even recompile unchanged folders/files, let alone changing strings.xml. So the pursue for a solution continues.
MMWolverine said:
Ok, tried with XXELL5 stock framework and tested some others as well, but no luck I'm afraid. The app is BeautifulWidgets, which I'm trying to translate into Slovenian language. The problem is I cannot even recompile unchanged folders/files, let alone changing strings.xml. So the pursue for a solution continues.
Click to expand...
Click to collapse
That's very strange. I will take look at that cause I even turned on my laptop. Will keep you informed.
Edit: Mate I checked it. And I also fail. The strange thing is I got also an older apk from version 4 of beautiful widgets and had no problem with it. Then I checked the newer version 5 and then the failure set in. I tried to take the files like android manifest from the older apk but still fail.
Throwing out of the window from my flying Ferrari killer S3 driven by a proud omega team member
Guys can you post the apk here ?? Il try it out tomorrow... as im gonna fall asleep any moment...
Sent from my GT-I9300 using Tapatalk 2
Hi guys! I see many people trying to learn how to make roms, Here i show the easiest and shortest way on how anyone can begin making roms for the Galaxy S3.
Requirements:
Prepared CWM Stock Package.
Apktool
7-zip
Notepad ++
Setting Up, and Introduction
IF you have downloaded firmware from sammobile instead of zoot1's package, use this part for Setting up and introduction: http://forum.xda-developers.com/showpost.php?p=37812381&postcount=33
OR ELSE THE EASIER WAY
To start with, Download the prepared CWM Stock Rom by zoot1 here: http://forum.xda-developers.com/showthread.php?t=1868004
I personally use firmware from sammobile, because i like to do everything myself. Though this method would be easier for beginners.
Extract the zip file to folder called "ROM".
Now lets head towards the customizing.
Thanks to Prawesome alot for this part. I took some info from his guide.
So now, open up the system folder. You'll find loads of folders in it. Here is a brief introduction to each of those folders:
1. apps
When you open this folder. You will find apk's. An apk is an install-able app package for any Android Device.
You can delete specific apps incase you want to delete. But take extra precautions on what you're deleting. As some apps are useful. You can add apps here as well in formats of apk's. But note, adding Play Store apps to the system/app folder is not recommended. For example you don't want Google Talk in your rom, you just have to delete the Talk.apk.
2. bin
Nothing really to mod in this folder. Full of advanced techy stuff. xD
3. etc
Here is where most of the tweaks come in. There is a folder called init.d where mods like the V6 Supercharger or multi-tasking fixes can be applied. Note! Don't add more than 1 or 2 scripts. Most of them usually conflict with each other.
In the gps.conf file, you can edit your gps info to make the gps more accurate. Pretty good guides about this, search them out.
Next is the hosts file. Devs use this to block sites from generating ads, and keeping their roms ad-free. Take a look at my DroidS3 hosts file, there are over 20,000 hosts blocked. You can use the same hosts file for your rom too.
4. Fonts
Very easy folder to understand. All you need to do here is replace ttf files, and you'll change the fonts.
5. Framework
Here is where the big mods come in. I'll explain further on about this. It contains the android.policy.jar, a useful element to add many mods. Framework-res is used to change wallpapers and theme the rom. I'll explain later.
6. libs
Contains all the libs needed for specific system apps to work. Don't mess here unless you're adding a mod.
7. Folders like csc, hdic, sipdb, wakeupdata, vendor, excetra..
These are the folders, there isn't much to do. Csc folder contains the feature.xml where some mods can be added. Search the forums for that. The rest contain multi-languages and more stuff.
8. xbin folder
Used to add scripts like busybox, dexdump, openvpn support. More like the bin folder but smaller.
9. Build.prop
Ever wondered how some roms have android 5.0, when it hasn't even released? All you need to change is the ro.build.version.release to any number you like. Even Android 20! Go change it, and fool some noobs out there. More mods can be added to this file. e.g:
Code:
debug.sf.hw=1
video.accelerate.hw=1
debug.performance.tuning=1
profiler.force_disable_err_rpt=1
profiler.force_disable_ulog=1
ro.config.nocheckin=1
ro.media.enc.jpeg.quality=100
ro.media.dec.jpeg.memcap=8000000
ro.media.enc.hprof.vid.bps=8000000
ro.telephony.call_ring.delay=0
ro.lge.proximity.delay=15
mot.proximity.delay=15
ro.ril.disable.power.collapse=0
pm.sleep_mode=1
ro.config.nocheckin=1
The codes listed above are for improving jpeg quality, saving some battery life, reducing call delay and more. Search for build.prop mods, you'll find loads of them. Now, a small explanation of the Meta-inf folder.
In Meta-Inf you'll find the updater-script.
Since this is aimed at beginners, I'll just show you how to change what text is shown during install in CWM.
Just edit what's in the quotes of the ui_print code in the file, and enter your own text. e.g:
Code:
ui_print("Hi, This message in quotes is displayed in recovery");
Modding!
It's time for the modding to begin.
Get apktool from: http://forum.xda-developers.com/showthread.php?t=1755243
Now, first copy your framework-res from the /system/framework directory to where you extracted apktool files. Let's call this folder "apktool"
Open the folder apktool, press shift and right click. Click on "Open command window here". Type:
Code:
apktool if framework-res.apk
Now you are ready to decompile apk's.
I'm going to show you how to mod different files. Copy over:
SystemUI.apk
android.policy.jar
framework-res.apk
1. SystemUI.apk
Just showing you basic modding here. Copy over SystemUI.apk to apktool folder. In the command prompt, type
Code:
apktool d SystemUI.apk
After it's done, you should see a SystemUI folder in the apktool directory.
I'm going to show you how to make the status bar transparent, thanks to raubkatze for this part.
Navigate to res/layout/tw_super_status_bar.xml and change android:background to match the red line.
Code:
<com.android.systemui.statusbar.phone.StatusBarWindowView [B][COLOR="Red"]android:background="#00000000[/COLOR][/B]" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
Save and close.
Then navigate to /res/values/drawables.xml
Edit to match:
Code:
<item type="drawable" name="status_bar_background">[COLOR="red"][B]#00000000[/B][/COLOR]</item>
That's it. Save and close.
Go back to your command prompt and type
Code:
apktool b SystemUI SystemUI-new.apk
After it's done, probably will take around 5-10 minutes. You'll find SystemUI-new.apk in your apktool folder. Open both SystemUI.apk and SystemUI-new.apk with 7-zip. Delete AndroidManifest.xml from SystemUI-new.apk and copy AndroidManifest.xml and META-INF from SystemUI.apk to SystemUI-new.apk
That's it. Close the zip files.
If you have adb or android-sdk push SystemUI-new.apk to your phone using:
Code:
adb remount
adb push SystemUI-new.apk /system/app/SystemUI.apk
adb reboot
If you don't have adb, just copy over SystemUI-new.apk to your phone. Rename it to SystemUI.apk and copy to system/app with root explorer. Reboot.
There you have transparent statusbar now!
2. android.policy.jar
Decompile android.policy.jar with:
Code:
apktool d android.policy.jar
You will find android.policy.jar.out, open it and use Cristiano Matos guide to mod the files: http://forum.xda-developers.com/showthread.php?t=2018633
After that use:
Code:
apktool b android.policy.jar.out
Open the android.policy.jar.out folder, you will find a dist folder created and inside that is your modified android.policy.jar.
You can use adb again by:
Code:
adb push android.policy.jar /system/framework
or the normal root explorer method.
3. framework-res.apk
Here i'll show you small mods.
Decompile it using
Code:
apktool d framework-res.apk
Navigate to res/values/bools.xml. Here you can add these. Thanks to DSA for this! :
4 Way Rotation:
Code:
Code:
<bool name="config_allowAllRotations">false</bool>
Change to:
Code:
Code:
<bool name="config_allowAllRotations">true</bool>
Lock Screen Rotation:
Code:
Code:
<bool name="config_enableLockScreenRotation">false</bool>
Change to:
Code:
Code:
<bool name="config_enableLockScreenRotation">true</bool>
and
Code:
Code:
<bool name="lockscreen_isPortrait">true</bool>
change to
Code:
Code:
<bool name="lockscreen_isPortrait">false</bool>
Disable Keyboard Switch In StatusBar When Typing
Code:
Code:
<bool name="show_ongoing_ime_switcher">true</bool>
Change to:
Code:
Code:
<bool name="show_ongoing_ime_switcher">false</bool>
Unplugging From USB doesn't Turn Screen On
Code:
Code:
<bool name="config_unplugTurnsOnScreen">true</bool>
Change to:
Code:
Code:
<bool name="config_unplugTurnsOnScreen">false</bool>[/indent]
Now to change wallpaper. Change the default_wallpaper.jpg in drawable-xhdpi and to change lockscreen wallpaper change keyguard_default_wallpaper.jpg.
Now recompile using:
Code:
apktool b framework-res framework-new.apk
Delete AndroidManifest.xml from framework-new. Copy AndroidManifest.xml and META-INF from framework-res.apk to framework-new.apk
To test use adb:
Code:
adb push framework-new.apk /system/framework/framework-res.apk
Or rename to framework-res.apk and copy to system/framework using root explorer. Reboot.
Once you've added everything, your modified apks. Ui_print mods, A custom kernel (just replace boot.img) it's time to compile. Now this is really easy. Just highlight all the folders/files like system, meta-inf and boot.img. Right click. Hover over 7-zip and click Add to Rom.zip. Wait for it to be done, and copy Rom.zip to your sd card and flash. Voila! You've made your rom!!
You can get more mods to add from here: http://forum.xda-developers.com/showpost.php?p=26583654&postcount=4
I was a beginner once, everyone was a beginner once. People helped me, and now I want to help people.
Press the Thanks button, and/or rate this thread 5 stars to show your support.
FAQ
- How do i add a mod?
To add a mod, just download it. Open it and copy over all the folders from the zip file EXCEPT the META-INF.
- How can i set up apktool on windows?
To set up apktool on windows, you need aapt, apktool.jar and apktool.bat
- My modified apk is not working?
Do some testing and get to know what went wrong. I'm always here. I'll be glad to help.
- Are these the only apps i can modify?
Ofcourse not! Any apk can be modified. Just decompile it, and make your changes.
- I'm looking for a guide on something i want to learn. Can you add it here?
I'll try my best.
Reserved
Reserved one more.
Any feedback guys? I hope this is useful.
Forget that i had to reserve one more.
R: [GUIDE] Beginners/Ref Guide to Making Roms.
Looks interesting...when i will finish my exam i will check with more attention
Sent from my GT-I9300 using xda app-developers app
Willy89 said:
Looks interesting...when i will finish my exam i will check with more attention
Sent from my GT-I9300 using xda app-developers app
Click to expand...
Click to collapse
Thanks. Glad it's of help.
Sent from my GT-I9300 using xda premium
Thnx for making this thread.
It's always useful to read thread's like this.
Nice job.
Verzonden door mijn GT-I9300 met xda premium
Great guide, thanks, I will point Theshawty in this direction :thumbup::thumbup:
slaphead20 said:
Great guide, thanks, I will point Theshawty in this direction :thumbup::thumbup:
Click to expand...
Click to collapse
Too late old man. Not interested in building roms anymore.
Thanks guys.
If there's anything you'd like to have added.
Let me know.
AW: [GUIDE] Beginners/Ref Guide to Making Roms.
Thanks. That's it what i searched for to start. Great.
weli..this would be intersting..and will c hw thread moves...
I Need Help In Building the ROM
Hi,
I am steinert. i need your help in biulding the rom, actually i finished everything but getting the problem while flashing the rom. when i googled it. i came to know that the problem lies in updater-script. i used root explorer to find out the reason. it was like.
FINISHED EXECUTING SCRIPT FILE
EXIT VALUE:126
STDOUT:
NULL
STDERR:
SH:<STDIN>[1]:/CACHE/RECOVERY/LAST_LOG:CAN'T EXECUTEERMISSION DENIED.
I Hope that You help a NOOB like me....
Thank you in advance....
Jacqueline Steinert said:
Hi,
I am steinert. i need your help in biulding the rom, actually i finished everything but getting the problem while flashing the rom. when i googled it. i came to know that the problem lies in updater-script. i used root explorer to find out the reason. it was like.
FINISHED EXECUTING SCRIPT FILE
EXIT VALUE:126
STDOUT:
NULL
STDERR:
SH:<STDIN>[1]:/CACHE/RECOVERY/LAST_LOG:CAN'T EXECUTEERMISSION DENIED.
I Hope that You help a NOOB like me....
Thank you in advance....
Click to expand...
Click to collapse
After flashing the rom.
Check the error through Advanced > Show recovery log in recovery.
Post results here.
I : checking for entendedcommand..
I : skipping execution of extendedcommand, file not found...
Jacqueline Steinert said:
I : checking for entendedcommand..
I : skipping execution of extendedcommand, file not found...
Click to expand...
Click to collapse
Huh?
Get me a screenshot of your meta-inf/com/google/android directory.
What exactly did you modify? It should work if you left the meta-inf untouched.
masterex567 said:
Huh?
Get me a screenshot of your meta-inf/com/google/android directory.
What exactly did you modify? It should work if you left the meta-inf untouched.
Click to expand...
Click to collapse
I just removed all the apps and inserted new apps...!!
Should i send you my updater-script?
Jacqueline Steinert said:
I just removed all the apps and inserted new apps...!!
Should i send you my updater-script?
Click to expand...
Click to collapse
Removed all?
Some are core apps like SystemUI, etc.
Get me a screenshot of your rom.zip..
masterex567 said:
Removed all?
Some are core apps like SystemUI, etc.
Get me a screenshot of your rom.zip..
Click to expand...
Click to collapse
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
This is the screenshot of my rom..! and before also i got the same problem with out changing the system .apk's
Jacqueline Steinert said:
View attachment 1700664
This is the screenshot of my rom..! and before also i got the same problem with out changing the system .apk's
Click to expand...
Click to collapse
Highlight those 3 and in 7zip options click add to " ".zip
Sent from my GT-I9300 using xda premium
[Hey guys Aditya here. After a month or so i'm posting tutorial and basic decompiling compiling using adb command!
THINGS YOU WILL NEED
ON WINDOWS PC
1) Winrar
2) 7zip
3) Java
4) Apktool and adb tools!!!!! (Many tools are available download anyone of them)
5) notepad+ AWESOME THING
ON UBUNTU
1) Java
2) Android SDK
3) APKTOOL ofcourse
Let's get started! I asume you using a Windows PC
First of all download and install JAVA
From here
Download Latest Apktool, extract to :
Windows XP : C:\Document and setting\folder your computer name
Windows 7 : C:\user\folder your computer name
copy your apk & framework-res.apk/SemcGenericUxpRes.apk/framework 2 to same folder with apktool
Now you can start Editing apk
Example Editing Walkman
Open Command Prompt (CMD)
TO DECOMPILE
Code:
java -jar apktool.jar if framework-res.apk
java -jar apktool.jar d semcmusic.apk ( can be whatever name you give to your apk )
Some apks need dependies like tw-framework.apk
Code:
java -jar apktool.jar if framework-res.apk
java -jar apktool.jar if semcgenericuxpres.apk
java -jar apktool.jar d your.apk ( can be whatever name you give to your apk )
Now you can edit what you like to. E.g. Res layout etc!
(For more detalis refer Post #3)
TO COMPILE
To compile back the edited apk
Code:
java -jar apktool.jar yourapkname.apk
For signing apk just drop the android manifest and meta inf of older apk or original apk!!!!!!
F.A.Q
A.I'm getting error while compiling apk??
Check if you have installed framework-res.apk most of compiling errors are becoz of this
B.Can apktool batch decompile and recompile apk's??
Yes,many of modded apk manegers or tools can batch decompile and recompile apk's!!
C.Can i MOD any system app using apk tool?
Yes it can mod all types of apk's just make sure you have correctly installed framework and all other dependices!!!!
D.My modded apk is not working! What should i do???
This question is mostly asked to me! Firstly check weather you have put the Meta-Inf from original APK as this folder contain signatures required for apk to get install.Secondly if you have modded some xml check its correct or some code or values are wrong.If any values or wrong code can lead us to FC or Bootloop..!!!
Using ADB and taking logcat!!!!!
USING ADB AND TAKING LOGCAT
What ia adb??
adb stands for Android Debugging Bridge
For what it is used for
adb is commonly used to pull,push,taking system dumpFOR TAKING LOGCAT
What you will need
On windows
1) Java (Hmmm not needed but u should have. )
2) adb tools by me http://d-h.st/vHJ
Now to make it easy first of all check you have enabled USB Debugging in phone its in Developer Options.
PROCDURE
Make a new folder in C Drive
Extract these tools into it (Asume you folder name is adb)
Now open cmd
Code:
type cd..
cd.. again
cd adb
adb
Now you have installed adb on your PC!
TAKING LOGCAT
Code:
adb logcat>logcat.txt
For only redio related log type
Code:
adb -r logcat>logcatr.txt
For only errors type
Code:
adb -v logcat>logcate.txt
Push and pulling apps from system!
Pushing Apps
Pushing app is installing app on its intenrnal memory!Its simple and doesn't need extra powers!
Code:
adb push yourappname.apk /system/app or /system/framework
Place the app in the adb folder
Pulling Apps
Pulling app is to take out your system apps or frameworks etc!
Code:
adb pull /system/app or /framework yourapp.apk
By this method you can take a system dump
Code:
adb pull /system
Understanding Logcats!!!!!
Some keyword's that represent's error'
Code:
"E/" - error
"E/dalvikvm" - possibly crucial system error
"No such file or directory" - says it all
"couldn't" - android likes that, mostly shows faulty things.
"fail"/"failed" - mostly crucial error
"W/"/"warning" - says it all, but not always warn could be a boot failure cause
"exception"(especially NullPointerException) - points you that something went wrong in framework or application work
These type of errors help us understand the error's and we can easily call out from these bugs or errors!!!
Most common errors occuring in an logcat!
"couldn't find native method", the most common reason of a bootloop.
This error causes most of bootloop problems!!!
For example
Code:
E/dalvikvm( 100): ERROR: couldn't find native method
E/dalvikvm( 100): Requested: Landroid/view/GLES20Canvas;.nStartTileRendering:(IIIII)V
E/JNIHelp ( 100): RegisterNatives failed for 'android/view/GLES20Canvas', aborting
As you can see! The main reson for this error is smali present in android/view of framework.jar called GLES20Canvas.smali
This happens while you are trying to port ROMS!!!!
Now if you are having bugs in other apkor jars how can u find ahem! i.e logcat gives us only the location of smali files and not the name of apk or jar! For that you have to study hole android code sources! Some common folders i have posted here!!
Code:
"com/android/server" - services.jar (there is the same folder at framework.jar but most likely you don't need to touch it).
another place we could be mixed up:
"com/android/internal" - framework.jar
"com/android/internal/policy/impl/" - android.policy.jar
for framework.jar path ends up on internal, which represents telephony folder. policy/impl is the only android.policy.jar folder.
Other frameworks are actually not used in port as they contain core android functionality which is common.
Simple MOD's
Now you guy's have idea about how to take a Logcat,use adb,use apktool.
NOW SOME REAL STUFF
MOD's Related to SystemUI.apk
We will start with simple MOD's! Like replacing icons and to some extend changing layout!
Now we will start will replacing icons inside the SystemUI.apk
First of all pull app from /system/app using adb Refer #2
Then copy that app to apktool folder! Type this cmd
Code:
java -jar apktool.jar d SystemUI.apk
Now go to out folder of SystemUI.apk!
Will find META-INF! RES! ANDROID.manifest
Now Navigate to res/drawable-hdpi as our device uses HPDI
You will find many icons now be carefull here! If youare expert n photoshop or any bitmap editor eit these icons! Or search it! Google it you will find many!
Replace these default icons by ur edited once or downloaded once!!
XML EDITING
Some XML's are not so complicated as other once! Some xml's have just true or false! Example
Code:
<bool name="config_hardwareAccelerated">true</bool>
This tells me that Hardware Acceleration is enabled you can disable it by replacing true by false! You just need to experiment around!
Smali Editing!
Coming soon!
Patching!
Coming soon :d
Changelog
CHANGELOG
1 July Monday 6.04pm -- Inital Editing
Old info but very usefull for noobs. Keep it up
:thumbup:
Hit thanks if you think I helped you.
Sent from LG Nexus 4
Thats really awesome keep it coming am a noob and I rly want to learn n b a part of z dev team
Sent from my GT-I9082 using xda app-developers app
For apk editing there are many 3rd party softwares which doesn't requires one to write such huge codes for signing and etc .
Kinda old method
Make.Believe
Razor! said:
For apk editing there are many 3rd party softwares which doesn't requires one to write such huge codes for signing and etc .
Kinda old method
Make.Believe
Click to expand...
Click to collapse
Yup . Like chotu tools
Sent from my GT-I9082 using xda premium
WARNING: INSTALL GOOGLE´S ANDROID SYSTEM WEBVIEW FROM THE PLAYSTORE / GAPPS FIRST
https://play.google.com/store/apps/details?id=com.google.android.webview
Do you wan´t to use google´s updatable webview on a cm rom?
well too bad, even if you install and disable the built in webview, the system still dosen´t uses it, so what can we do?
modify a config in the framework called
"config_webViewPackageName" from com.android.webview to com.google.android.webview
you can do this via xposed with http://repo.xposed.info/module/net.typeblog.webview
however xposed for 5.1 is glitchy and will break a lot of optimizations if you are running a based cm run that has those.
so the solution? well flash the zip below, its a modified framework from cm12-13/04/2015 (DD/MM/YY btw)
https://drive.google.com/open?id=0BwduAK2l37OaSUprcG5LejNiS2s&authuser=0
Instructions:
Download zip from the link provided
Flash via recovery
??
profit
this is mine
BTW: I didn´t test on any other device, altought i dont think it will work since our framework contains some hammerhead-specific values
Thank you lord! I was searching for this for so long. This is going to be awesome to me!!
Best Regards,
Jairo.
May I ask how you did it? I decompiled framework-res.apk in Chroma ROM and then I navigated to "\framework-res\res\values" but I didn't find a config.xml file. Isn't this where the modification is done? Am I doing something wrong? @opssemnik
fr3quency said:
May I ask how you did it? I decompiled framework-res.apk in Chroma ROM and then I navigated to "\framework-res\res\values" but I didn't find a config.xml file. Isn't this where the modification is done? Am I doing something wrong? @opssemnik
Click to expand...
Click to collapse
its /res/values/strings.xml
opssemnik said:
its /res/values/strings.xml
Click to expand...
Click to collapse
I found it after decompiling your framework-res.apk and searching from Windows Explorer.
I went into strings.xml and replaced "com.android.webview" with "come.google.android.webview". Then I recompiled and pushed the new framework-res.apk to /system/frameworks(I had some translation errors but it was first time seeing who things). Anyway, the system doesn't boot at all and shows only the bootanimation for 15+ minutes. Could you help me?
I downoaded this folder: http://www.droidviews.com/tutorial-how-to-decompile-and-recomplie-apk-files/ and replaced the apktool inside of it with this one: http://forum.xda-developers.com/showpost.php?p=59436776&postcount=2812
I installed the framework via "apktool if framework-res.apk" just in case.
fr3quency said:
I found it after decompiling your framework-res.apk and searching from Windows Explorer.
I went into strings.xml and replaced "com.android.webview" with "come.google.android.webview". Then I recompiled and pushed the new framework-res.apk to /system/frameworks(I had some translation errors but it was first time seeing who things). Anyway, the system doesn't boot at all and shows only the bootanimation for 15+ minutes. Could you help me?
I downoaded this folder: http://www.droidviews.com/tutorial-how-to-decompile-and-recomplie-apk-files/ and replaced the apktool inside of it with this one: http://forum.xda-developers.com/showpost.php?p=59436776&postcount=2812
I installed the framework via "apktool if framework-res.apk" just in case.
Click to expand...
Click to collapse
after you recompile it, you must put the META-INF folder from the original apk into your new APK,then push it to system/framework and set its permissions to 644 (rw-r-r)
opssemnik said:
after you recompile it, you must put the META-INF folder from the original apk into your new APK,then push it to system/framework and set its permissions to 644 (rw-r-r)
Click to expand...
Click to collapse
It still doesn't boot and stays at bootanimation. I decompiled and recompiled the .apk again and using WinRar i copied the META-INF folder from the original .apk to the new one. Then I rebooted into recovery and typed these commands:
Code:
adb shell
cd system/framework
rm framework-res.apk
adb push framework-res.apk /system/framework (This is the recompiled apk with the META-INF folder)
adb shell chmod 644 /system/framework/framework-res.apk
adb reboot
Edit: I didn't install Google WebView this time.
fr3quency said:
It still doesn't boot and stays at bootanimation. I decompiled and recompiled the .apk again and using WinRar i copied the META-INF folder from the original .apk to the new one. Then I rebooted into recovery and typed these commands:
Code:
adb shell
cd system/framework
rm framework-res.apk
adb push framework-res.apk /system/framework (This is the recompiled apk with the META-INF folder)
adb shell chmod 644 /system/framework/framework-res.apk
adb reboot
Edit: I didn't install Google WebView this time.
Click to expand...
Click to collapse
install it from the playstore before doing this, also are you lastest snapshot apktool ? (its newer than rc4)
opssemnik said:
install it from the playstore before doing this, also are you lastest snapshot apktool ? (its newer than rc4)
Click to expand...
Click to collapse
The apktool I used is newer... I think; it was posted at a later date, thus newer. Could you upload your folder with your apktool that you used if you have enough bandwidth?
Edit: I installed it from the Play Store and pushed the .apk. Is there a way to see if it used Google or AOSP webview?
Will do once i get home
See the user agent or read the config , altought the latter probably will nerd system permissions.
Or you could delete system webview and see if webkit based apps still work
Since framework is updated regularly in cm nightlies, so is there any way to do this on the fly using latest framework files.
Thnx
fr3quency said:
The apktool I used is newer... I think; it was posted at a later date, thus newer. Could you upload your folder with your apktool that you used if you have enough bandwidth?
Edit: I installed it from the Play Store and pushed the .apk. Is there a way to see if it used Google or AOSP webview?
Click to expand...
Click to collapse
did you get it after all? if not i upload my apktool folder
prabhu_91 said:
Since framework is updated regularly in cm nightlies, so is there any way to do this on the fly using latest framework files.
Thnx
Click to expand...
Click to collapse
would require a custom build of cm with it, or a custom apk of the webview or a xposed module(see OP) or apktool / some kind of apk modifying program to be native compiled for android(so it could be ran as an addon.d script on recovery). you could always keep flashing older framework-res, generally cm dosen´t do much to it, but once it does, the mod will need to be updated.
BTW, making for VIVID-20150426v3
opssemnik said:
did you get it after all? if not i upload my apktool folder
Click to expand...
Click to collapse
Yeah I got it working. Thanks for the help!
Sorry ignorance, but what is the function of this file?
i need com.android.webview
could you please upload a com.android.webview flashable zip. i don't want com.google.android.webview, i'm facing major issue with google's updatable webview. i need a aosp webview. plz help me