[Q] Why won't my changes in framework-res.apk load? - General Questions and Answers

Working from rooted 2.3.3 (on a Droid X2, but I don't think that matters).
I have pulled /system/framework/framework-res.apk from the phone, unzipped, modified exactly one file (\res\drawable-hdpi\zz_moto_list_texture_bg.png) with photoshop, zipped back up (7-zip), zipaligned and pushed back into the /system/framework/ directory with the correct permissions. The file was not re-signed.
The phone boots without error, but the new modified file does not get loaded, the old version of the graphic remains. I have double checked and my modified /system/framework/framework-res.apk is in place. I don't know where the phone is getting the old version from.
I have tried formatting the system cache, erasing all user data via android recovery, zipped with different levels of compression for the apk file (moderate to none), same result.
I had this problem before on 2.2.2, which I thought was corrected by formatting the cache, but I guess I was wrong and it got fixed by chance.
Does anyone know what can be done to force framework-res.apk in the /system/framework/ directory to load?
Relevant files attached.
Chris

Figured this out. There is a 5x5 graphic that colored the background texture. I had to change that too.
Chris

Related

[Q] ***pushing framework-res.apk help***

I edit the png files in the zip. Change the zip back to apk.
c:\>android\tools\adb push c:\framework-res.apk /system/framework/framework-res.apk
360 kb/s (4756622 bytes in 12.879s)
so no errors. shows just as successful as pulling the file
upon reboot, none of my changes appear.
If the permissions were incorrect, wouldn't i get an error specifying so?
How would i allow the system framework-res.apk to have the correct perms?
I even did this over again just incase i forgot something. Making sure the files were infact changed and stored back into the apk.
Just changing the battery and bottom of pulldown menu.
Any ideas?
Moto droid 2.2
rooted - Lithium Mod
DixieNormus said:
I edit the png files in the zip. Change the zip back to apk.
c:\>android\tools\adb push c:\framework-res.apk /system/framework/framework-res.apk
360 kb/s (4756622 bytes in 12.879s)
so no errors. shows just as successful as pulling the file
upon reboot, none of my changes appear.
If the permissions were incorrect, wouldn't i get an error specifying so?
How would i allow the system framework-res.apk to have the correct perms?
I even did this over again just incase i forgot something. Making sure the files were infact changed and stored back into the apk.
Just changing the battery and bottom of pulldown menu.
Any ideas?
Moto droid 2.2
rooted - Lithium Mod
Click to expand...
Click to collapse
Just my thoughts on this, maybe it helps you:
1. You could have changed the wrong png. Change something that you recognize to make sure it isnt that. I don't know how likely that is but the .apk I've messed with had some unused .png's.
2. The first time I ever messed with one I had a problem with it not reflecting my changes in text color. After a long time of frustration I zipaligned to go back to my previous .apk then it showed the changes.
3. Zipalign... unless you do so, you'll have a big performance hit by having Android extract everything form the .apk (and the framework-res is a relatively big one) as it is not optimized. It could also, as in my case be the answer to your problem.

[Q] Some question about making a custom rom

Hi
I hope someone can help me.
I am trying to make my own custom rom. I used this way.
- flashed xxJPM
- de odexed all apps and framework
- added stock android lockscreen
- removed some useless system apps
- then changed theme
all this works great. but I had problems with adding some other apps to /system/apps
1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib
But apps like quickpic or the gingerbread keyboard are not working. When I just install them android create a data folder. What do I have to do with those database files in this folder? Can someone show me the right way for installing own system apps?
Then I do a factory data reset in the settings. After this nothing was working. I had no lockscreen. Even all options by pressing the shutdown button except "shutdown" disappeared. Does anyone know why this happened?
I am new to this. So it would be great if you can help me.
cal.mar said:
Hi
I hope someone can help me.
I am trying to make my own custom rom. I used this way.
- flashed xxJPM
- de odexed all apps and framework
- added stock android lockscreen
- removed some useless system apps
- then changed theme
all this works great. but I had problems with adding some other apps to /system/apps
1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib
But apps like quickpic or the gingerbread keyboard are not working. When I just install them android create a data folder. What do I have to do with those database files in this folder? Can someone show me the right way for installing own system apps?
Then I do a factory data reset in the settings. After this nothing was working. I had no lockscreen. Even all options by pressing the shutdown button except "shutdown" disappeared. Does anyone know why this happened?
I am new to this. So it would be great if you can help me.
Click to expand...
Click to collapse
QuickPic/Gingerbread: Nope. Open the .apk and copy the lib files to /system/lib
About the rest. i have no idea since I don't know your internal files.
THIS IS DEVELOPMENT. DO NOT CLOSE.
It helps people with force close problems.
The Dark Lestat said:
QuickPic/Gingerbread: Nope. Open the .apk and copy the lib files to /system/lib
About the rest. i have no idea since I don't know your internal files.
THIS IS DEVELOPMENT. DO NOT CLOSE.
It helps people with force close problems.
Click to expand...
Click to collapse
dude he already added the lib files..so this is an un-usual problem
"1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib"
cal.mar said:
Hi
I hope someone can help me.
I am trying to make my own custom rom. I used this way.
- flashed xxJPM
- de odexed all apps and framework
- added stock android lockscreen
- removed some useless system apps
- then changed theme
all this works great. but I had problems with adding some other apps to /system/apps
1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib
But apps like quickpic or the gingerbread keyboard are not working. When I just install them android create a data folder. What do I have to do with those database files in this folder? Can someone show me the right way for installing own system apps?
Then I do a factory data reset in the settings. After this nothing was working. I had no lockscreen. Even all options by pressing the shutdown button except "shutdown" disappeared. Does anyone know why this happened?
I am new to this. So it would be great if you can help me.
Click to expand...
Click to collapse
After making your own dump your not suppose to factory reset, only after flashing your own dump your ready to factory reset, but if you factory reset while making a dump/removing and adding files, you will soft brick and loose your work..
Did you change the framework and tw framework?
Adding back some framework files via adb might help..
Or you will have to start over again..
I forgot to add that you should check your permissions on the lib file
Sent from my Alpha 17 1.2 GHz ACID Lestatious 2.0 BUILD 1.8 Galaxy 3 FROYO
rudolf895 said:
dude he already added the lib files..so this is an un-usual problem
"1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib"
Click to expand...
Click to collapse
After copying lib files give this command over adb..
chmod 777 /system/lib/filename.so
InDroid 4.0 (Build 6)
cal.mar said:
Hi
I hope someone can help me.
I am trying to make my own custom rom. I used this way.
- flashed xxJPM
- de odexed all apps and framework
- added stock android lockscreen
- removed some useless system apps
- then changed theme
all this works great. but I had problems with adding some other apps to /system/apps
1. I copied the *.apk file to /system/app
2. I extract the lib files into /system/lib
But apps like quickpic or the gingerbread keyboard are not working. When I just install them android create a data folder. What do I have to do with those database files in this folder? Can someone show me the right way for installing own system apps?
Then I do a factory data reset in the settings. After this nothing was working. I had no lockscreen. Even all options by pressing the shutdown button except "shutdown" disappeared. Does anyone know why this happened?
I am new to this. So it would be great if you can help me.
Click to expand...
Click to collapse
As for the lockscreen and power menu, i was having same problem few days back. Searched all over, no solution. In the end I had to start it all over again. I suggest u do the same.
InDroid 4.0 (Build 6)
arunmcops said:
As for the lockscreen and power menu, i was having same problem few days back. Searched all over, no solution. In the end I had to start it all over again. I suggest u do the same.
InDroid 4.0 (Build 6)
Click to expand...
Click to collapse
yeah I think you are right. Thank you all for your help. I'll try it again. And I hope that it will work.
HI ok. I've tryed it again.
But know when I want to flash my new factoryfs.rfs the Download crashed.
I don't know where the problem could be.​
Do I have to use this command?
dd if=/dev/block/stl6 of=/sdcard/factoryfs.rfs
Click to expand...
Click to collapse
Can someone explain this command to me?
still third time flashing chrashes.
when Odin is flashing the factoryfs.rfs it stops at a specific level. odin get 99% of CPU and I have to interupped it. What is my fault? DId anyone have same problems? I try it to make like all the tutorials says.
Edit: Odin says before flashing "Big Partition size!" What do I have to do to make it smaller?
Edit: I get this:
# dd if=/dev/block/stl6 of=/sdcard/factoryfs.rfs
dd if=/dev/block/stl6 of=/sdcard/factoryfs.rfs
435200+0 records in
435200+0 records out
222822400 bytes transferred in 115.950 secs (1921711 bytes/sec)
Click to expand...
Click to collapse
Found the problem why odin crashes. I copied the factoryfs.rfs file with 7zip into the .tar package but I had to use TotalCommander.
But still I have no lockscreen after flashing and the options in the power menu are not visible.

[Q] Modding SystemUI.apk, Stock Buttons

Ok well I don't like the default Asus buttons so I decided to get this http://forum.xda-developers.com/showthread.php?t=1120014
That was on the stock rom. I just flashed the Revolver rom however and noticed the icons were back to normal so I went through the process in the link like before however this time my wallpaper disappeared along with the navbar. I looked in Root Explorer and SystemUI was only a couple of kbs in size so obviously it got corrupted. I kept trying this method with the same result.
How else could I go about getting those buttons? Do I have to mod the SystemUI file manually and put them in, if so, how?
EDIT: Solved it. For anyone else experiencing issues with Metamorph, check out ZipThemer.
I manually add them from the linux command line. You have to use the update command to add them to the zip/apk. Don't sign the new apk after adding them.
unzip -l SystemUI.apk - look in the res folders
zip -ur SystemUI.apk res/blah/blah
for that last line, I just have a res/ directory with all the files that I want to replace in the proper subdirectories.
Good luck! use zip --help or unzip --help if you get stuck.

[Q] Services.jar changes, even simply deodexing the file prevents phone from booting

I am trying to make a minor change to my services.jar and so far have no been successful.
I deodexed the file with xultimate2.3.3 , extracted the classes.dex with 7zip 9.2, I used apktool 1.4.3 to "expand" the contents, made the change, repacked the dex file and put it back into services.jar and the phone cannot compelete boot. I made sure to change the permissions, owner a group to match the previous file.
I then tried using Xultimate to deodex the file and put it back on the phone and this also keeps it from booting.
I then tried using the already deodexed file from another rom (2.2.1 vs 2.2.2) and it had the same issue.
So far I have to reflash my phone with Odin every time and I am getting tired of making the same mistake over and over.
edit: Maybe I should ask - what is the appropraite way to move the file over? I am doing it by going into root explorer, deleting /system/framework/services.jar+services.odex, using adb push to put the file on the sdcard, using root explorer to move it from sdcard to /system/framework then changing the permissions in root explorer to match the previous file before finally running "chown root.root /system/framework/services.jar" from adb shell
Either my method for copying the file is bad or xultimate 2.3.3 is messing up the deodex. Any advice on another tool to use to deodex this file?
You should be using baksmali/smali to decompile/recompile classes.dex, not apktool :/
Apktool can decompile .jars too
I use it and works fine
@OP
After deodexing decompile the jar using Virtuous Ten Studio by Diamondback(Google it)
Burned from my laser torch using pencil cells
Thank you for the replies. I will try these suggestions.
As a side note I also tried to use Xultimate to deodex the file, then ran dexopt-wrapper on the output to reodex the unchanged file and the phone is stuck in a boot loop.
You can read about re-odexing files here http://themikmik.com/showthread.php...w-About-adb-odex-themes-etc&p=75225#post75225
Can you give suggestions on another tool to de-odex the services.jar file? I think xultimate is the problem. It is the only common denominator.
I forgot to add that the original services.odex is a different size and has different contents from the new services.odex created by xultimate+dexopt-wrapper
I didn't expect it to work but I took the modified/deodex services.jar from a 2.2.1 rom and put it into my 2.2.2 rom and it had the same non boot issue.
The newest version of xUltimate i could find.
Enjoy
http://www.xeudoxus.com/android/xUltimate-v2.4.2.zip

[Q] De-Odexed Framework not working

Hello all;
I have an LG p698 device, with a custom ROM (ZemDroid)(Gingerbread). Everything is working fine, but I wanted to add Arabic support to it, and for that, I need a deodexed framework.
I pulled the entire /system/framework directory, copied and modified the BOOTCLASSPATH as necessary, and used smali and baksmali 2.0.3. They reported no errors in disassembling the framework.odex file, created the "out" directory, and then using smali created the classes.dex file, which I shoved into the framework.jar file using Ark (Kubuntu 13.10).
I made a copy of the working framework.jar and framework.odex files on device, and put the new jar, and of course, deleted the odex.
wiped the dalvik cache for good measure, and rebooted.. The phone got stuck on LG logo :/ (It didn't even reach the custom splash image)
I can reboot into CWM, I can even adb into it in this state, but it won't continue starting up. Replacing original ones lets the device start normally, but my deodexed framework.jar won't :crying:
Any ideas?

Categories

Resources