I am trying to take some images and suck from a CM10 ROM and transfer to my ROM (stock touchwiz). I can decompile just fine and edit the files. (drawable-xdpi). But when i re-compile it, i get this really long error.
I've tried the following:
*Installing Both Touchwiz Framework and Framework (From my ROM)
*using the command:
Code:
apktool b -s systemui systemui.apk
(It wont let me use that code)
*Reinstalling the framework multiple times
*I even tried recompiling a non-edited version. That doesnt even work.
Any Suggestions?
I am needing to edit this for my ROM. v7 update needs to be released soon...
Droid Premium said:
I am trying to take some images and suck from a CM10 ROM and transfer to my ROM (stock touchwiz). I can decompile just fine and edit the files. (drawable-xdpi). But when i re-compile it, i get this really long error.
I've tried the following:
*Installing Both Touchwiz Framework and Framework (From my ROM)
*using the command:
Code:
apktool b -s systemui systemui.apk
(It wont let me use that code)
*Reinstalling the framework multiple times
*I even tried recompiling a non-edited version. That doesnt even work.
Any Suggestions?
I am needing to edit this for my ROM. v7 update needs to be released soon...
Click to expand...
Click to collapse
Take out the "-s"
Sent from my SAMSUNG-SGH-I727 using Tapatalk 2
I got the problem like this can any one tell what is it?
:\Users\the'e_000\Deskto.\apktool>apktool b -f -d app-debu-unali_ned.apk
Ixception in thread "main" brut.androlib.AndrolibException: brut.directory.PathN
.t xist: ap too .ym
at brut.androlib.Androlib.readMetaFile(Androlib.jaua:164)
at brut.androlib.Androlib.build(Androlib.jaua:183)
at brut.androlib.Androlib.build(indrolib.jaua:176)
at brut.apktool.Main.cmdBuild(Main.jaua:228)
at brut.apktool.Main.main(Main.jaua:79)
aused by: brut.directory.PathNotExist: apktool.yml
at .rut..irectory...stractlirectory.get'i e nput '.stractPlrectory.java:
RaE
at brut.androlib.Androlib.readMetaFileandrolib.jaua:160>
4 more
Related
I will be releasing the fix on my rom sometimes next week , and I will not compile this for every set up / theme / rom out there but if you know what you are doing this is pretty easy fix
Here is how the fix works :
Our present kernel source is 2.3.4 and we are running 2.3.6 base . So I looked at what was different in the wifi files from 2.3.4 to 2.3.6 and there you go .
Files attached at the end of the post are 2.3.4 JVQ (already modified for JVU)
(fyi these files come from apk manager just rename your jar files to apk to decompile them then copy the files attached at the end of the post in there respective places )
_framework.jar :
delete: \android\net\wifi\WifiStateTracker$1.smali
and copy paste the files attached and recompile
_services.jar :
copy paste the files attached and recompile
_'etc' folder copy paste into your /system folder in your rom/Phone
(not 100% sure its needed but better use them anyways)
IF you are not on JVU you need to change the ids manually , the names of the values are written in the smali so that will make it easier to port to other versions .
Tested on Belkin router (the worst of them all) and on public wifi with no dhcp assigned . after an hour no disconnect flawless victory
For beginers here is a guide by pantrif13 : http://forum.xda-developers.com/showpost.php?p=22032781&postcount=16
Credits to Shoman94 for pointing me in the right direction and providing files to help me diff(and being insistent about it )
suprstar for testing
and gtg465x who achieved this first on the SGS2
Will this fix the adhoc problem too ?
You are the master.
Sent from my GT-I9000 using xda premium
HSaber said:
Will this fix the adhoc problem too ?
Click to expand...
Click to collapse
well this fix the current wifi bug , rule of thumb if it was wokring back on JVQ for you , and it stopped after that , now it works .
try and tell us
I'm using it in my rom thank you!
Can some1 please explain me how to recompile...
Sent from my GT-I9000 using XDA App
burakgon said:
I'm using it in my rom thank you!
Click to expand...
Click to collapse
Pleasure.. Spam my thx button ?
Little mention on your credits maybe
To others if you don't know how to use apkmanager this mid is not for you
Tell your favorite rom dev about it it takes a few minutes to apply this
I could have kept this to my rom but I put it out there for all rom to use
This fix really works
DAGr8 said:
Pleasure.. Spam my thx button ?
Little mention on your credits maybe
To others if you don't know how to use apkmanager this mid is not for you
Tell your favorite rom dev about it it takes a few minutes to apply this
I could have kept this to my rom but I put it out there for all rom to use
This fix really works
Click to expand...
Click to collapse
Bootloop when I try it on odexed rom. (Deodexed applied odexed) JVU
burakgon said:
Bootloop when I try it on odexed rom. (Deodexed applied odexed) JVU
Click to expand...
Click to collapse
well use odex jvq ..
(fyi these files come from apk manager just rename your jar files to apk to decompile them then copy the files attached at the end of the post in there respective places )
_framework.jar :
delete: \android\net\wifi\WifiStateTracker$1.smali
and copy paste the files attached and recompile
_services.jar :
copy paste the files attached and recompile
_'etc' folder copy paste into your /system folder in your rom/Phone
(not 100% sure its needed but better use them anyways)
Click to expand...
Click to collapse
cant get the instrucstion newbie here..how can i use this one pls can u use much more clearer instructions for newbies..thank you very much in advance
Great work!
Thx for your time.
titaempoy said:
cant get the instrucstion newbie here..how can i use this one pls can u use much more clearer instructions for newbies..thank you very much in advance
Click to expand...
Click to collapse
As said in OP, until built for any ROM version: Be your own developer!
Adb pull the system .jar files, decompile with dependency, edit, compile, rename, adb push result.
are a beginner and I did not understand anything ,more clear PLEASE if you can, thanks!...I think your work is useful
I think many people could do with a step by step guide for this if anyone has the time to do it
Please note our desires about this topic...declared above..thanks!
romyo said:
Please note our desires about this topic...declared above..thanks!
Click to expand...
Click to collapse
I think that dagr8 explain very clear what needs to be done (but you need to have some experience with decompiling and compiling).
Here what you need to do in case you are on jvu:
1) First off all you need the latest JDK and JRE installed on your system.
2) Then go here to learn how to set up apktool.
3) After the setup of apktool pull the services.jar (services.odex if you have odex rom) and framework.jar (framework.odex in case of odex rom) and put it in your apktool folder
4)
a. If you are on deodex rom you only need to run these commands from the folder of apktool (go to apktool folder and press ctrl and shift -open command window here)
Code:
apktool d framework.jar
apktool d services.jar
You will find two new folders (servicesout and frameworkout)
Then do what dagr8 said in op.
b. if you are on odex rom: get the latest baksmali from here
then pull all your system/framework to your pc and put baksmali.jar there.
Open commant window and write:
for sevices:
Code:
java -jar baksmali.jar -c :core.jar:bouncycastle.jar:ext.jar:framework.jar:android.policy.jar:services.jar:core-junit.jar -xa 10 services.odex -o services.jar.out
for framework:
Code:
java -jar baksmali.jar -c :core.jar:bouncycastle.jar:ext.jar:framework.jar:android.policy.jar:services.jar:core-junit.jar -xa 10 framework.odex -o framework.jar.out
Then do what dagr8 said.
5)Both deodex odex: get the latest smali from here
Put it in the folder with out folders and write:
for services:
Code:
java -jar smali.jar sevices.jar.out -o classes.dex
you will find a new classes.dex file.Open services.jar with winrar and drag and drop (overwrite) there.
Then for framework:
Code:
java -jar smali.jar framework.jar.out -o classes.dex
Same here (open the jar with winrar and drag and drop)
5) if you are on deodex rom you finished just push the new services and framework to the system along with the files which provide dagr8 for etc folder.
6) if you are on odex...go here and follow the guide from the part odexing back...
I hope i helped!
Thanks a lot dagr8 for this!!
can dev provide the public.xml that this was made with for comparison of ids?
Thanks for your time and explanations given pantrif13 and dagr8, expecting something more simple ... you can install the CWM (example) ... so (who knows it's easy anyway)...expect other solutions!!!to solve the problem with wifi...
Great job. Thanks
i m on jw1 deodex jetpack custom rom 8.2 and i am using the jvt modem...
will you provide fix for jw1 rom next days? thank you !!!
i am having trouble compiling apk's from a cm9 rom. i can decompile just fine with apktool. can anyone point me in the right direction
Did you set the framework-res?
EDIT: apktool if framework-res.apk --I was kind of vague
yes i did setup the framework this is the errors im getting
c:\apktools>apktool b mms.apk
Exception in thread "main" brut.androlib.AndrolibException: brut.directory.PathN
otExist: apktool.yml
at brut.androlib.Androlib.readMetaFile(Androlib.java:142)
at brut.androlib.Androlib.build(Androlib.java:159)
at brut.androlib.Androlib.build(Androlib.java:154)
at brut.apktool.Main.cmdBuild(Main.java:182)
at brut.apktool.Main.main(Main.java:67)
Caused by: brut.directory.PathNotExist: apktool.yml
at brut.directory.AbstractDirectory.getFileInput(AbstractDirectory.java:
103)
at brut.androlib.Androlib.readMetaFile(Androlib.java:138)
... 4 more
c:\apktools>
I remember with APKTool I always had to rename it.
By that I mean, apktool b MMS MMS2.apk
So apktool b FolderName NameOfAPK.apk
Try that. If not someone else will have to step in. A last resort would be to try APKManager or APK Multi-tool.
Update apktool and put it in the sdk platform tools folder then update the sdk with 4.0 stuff then run this command and keep an ics framework-res.apk in the same platform-tools folder.
apktool if framework-res.apk
Then proceed with
apktool d whateverapp.apk
This was the only way I could get it to work.
Sent from my SPH-D700 using Tapatalk
You might also want to try the version before the latest. I read that somewhere.
You can also try decompiling with the one version old one and compiling with the new one.
Sent from my SPH-D700 using Tapatalk
Did this work for you?
In Soviet Epic forum, clockworkmod root you!
every time i'm trying to decompile an APK i get this error:
Code:
Decompiling Apk
testCan't find framework resources for package of id: 2. You must install proper framework files, see project website for more info.
"An Error Occured, Please Check The Log (option 24)"
can someone help me?:crying:
someone? anyone?
:crying:
make sure you installed correct framework apps..and then decompile again
arpith.fbi said:
make sure you installed correct framework apps..and then decompile again
Click to expand...
Click to collapse
I already installed the framework-res.apk and the systemui.apk
Sent from my LT18i using xda premium
can you post the 4-5 previous lines in the code before getting error?
arpith.fbi said:
can you post the 4-5 previous lines in the code before getting error?
Click to expand...
Click to collapse
i used used apk multi tool, so i selected a project, chose to decompile, and that are all the lines i get.
install original stock framework-res.apk including other frameworks
First try decompiling and re-compiling the original stock apk before decompiling & recompiling apk of some other roms.
but i still feel framework-res.apk isnt properly installed
Code:
apktool install-framework framework-res.apk
apktool if framework-res.apk
/1.apk successfully created.
apktool if SemcgenericUXpres.apk
/2.apk successfully created..
After that try it.. ıt works lots of apk instead of systemUI.apk :S I dont know where I have mistakes during COMPILE process :/
Erhany said:
apktool if framework-res.apk
/1.apk successfully created.
apktool if SemcgenericUXpres.apk
/2.apk successfully created..
After that try it.. ıt works lots of apk instead of systemUI.apk :S I dont know where I have mistakes during COMPILE process :/
Click to expand...
Click to collapse
thanks, it worked
now i can't compile the apk:crying:
Code:
The system cannot find the file specified.
what can i do to fix that?
please, can someone help me with that?
Guys i really got bored this apktool compile errors!
I tried a lot of apktool manager .jar aapt versions but result is same!
1.apk referred to my framework-res.apk on Xperia ARC!
I can decompile but can not compile..
Im searching xda and google for a result but theres not any chances..
JDK SDK(full from 4.1 to 1.5/6) JDR JAVA latest versions..
All I want to edit xml's from SystemUI.apk but with no changes cant compile too..
heres the log
I: Smaling...
Exception in thread "main" java.lang.NullPointerException
at org.jf.util.PathUtil.getRelativeFile(PathUtil.java :44)
at org.jf.smali.smaliFlexLexer.getSourceName(smaliFle xLexer.java:2569)
at org.antlr.runtime.CommonTokenStream.getSourceName( CommonTokenStream.java:345)
at org.antlr.runtime.tree.CommonTreeNodeStream.getSou rceName(CommonTreeNodeStream.java:106)
at org.antlr.runtime.tree.TreeParser.getSourceName(Tr eeParser.java:78)
at org.jf.smali.smaliTreeWalker.getErrorHeader(smaliT reeWalker.java:349)
at org.antlr.runtime.BaseRecognizer.displayRecognitio nError(BaseRecognizer.java:192)
at org.antlr.runtime.BaseRecognizer.reportError(BaseR ecognizer.java:186)
at org.jf.smali.smaliTreeWalker.smali_file(smaliTreeW alker.java:428)
at brut.androlib.mod.SmaliMod.assembleSmaliFile(Smali Mod.java:85)
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexF ileBuilder.java:43)
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexF ileBuilder.java:33)
at brut.androlib.src.SmaliBuilder.buildFile(SmaliBuil der.java:64)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder. java:48)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder. java:35)
at brut.androlib.Androlib.buildSourcesSmali(Androlib. java:222)
at brut.androlib.Androlib.buildSources(Androlib.java: 179)
at brut.androlib.Androlib.build(Androlib.java:170)
at brut.androlib.Androlib.build(Androlib.java:154)
at brut.apktool.Main.cmdBuild(Main.java:182)
at brut.apktool.Main.main(Main.java:67)
I tried decompilin with original apktool and compile back ICSapktool too. no success..
Im on GB but havng same errors on ICS too!
Update aapt.exe, grab it from your android sdk folder and place inside apktool dir, old aapt.exe has known bugs that prevent it from recompiling.
Sent from my LT18i using xda app-developers app
Hey so I have noticed that Charles_l has made a Pixel home button animation for the Nexus 5X (found here : http://forum.xda-developers.com/nexus-5x/themes-apps/mod-pixel-navigation-bar-home-button-t3498614) and wanted to reverse engineer his work so I can port it to other devices. An important thing that I noticed was that he deodexed the SystemUI.odex file and build it back into the SystemUI.apk so he can add files found in the Pixel's odex files.
Now my first step to reverse engineer was to figure out how to deodex the odex files and build them into the apk. At the moment I have downloaded the baksmali.jar and smali.jar from JesusFreke ( https://bitbucket.org/JesusFreke/smali/downloads ) and shifted them to a folder to work in. I have extracted the odex files from the Nexus 5X
Code:
adb pull /system/priv-app/SystemUI.apk/oat/arm64/SystemUI.odex
and extracted the framework for baksmali to work with
Code:
adb pull /system/framework/arm64/
I then moved all the files to the folder containing the baksmali.jar file and ran the command to extra all the smali files
Code:
java -jar baksmali.jar x -c boot.oat SystemUI.odex -o SystemUI
Now I was wondering, How do you build them into the apk? I have tried a few things but they just cause the SystemUI to crash once booted.
If anyone can tell me how to fix this, then please tell me.
Jackio987 said:
Hey so I have noticed that Charles_l has made a Pixel home button animation for the Nexus 5X (found here : http://forum.xda-developers.com/nexus-5x/themes-apps/mod-pixel-navigation-bar-home-button-t3498614) and wanted to reverse engineer his work so I can port it to other devices. An important thing that I noticed was that he deodexed the SystemUI.odex file and build it back into the SystemUI.apk so he can add files found in the Pixel's odex files.
Now my first step to reverse engineer was to figure out how to deodex the odex files and build them into the apk. At the moment I have downloaded the baksmali.jar and smali.jar from JesusFreke ( https://bitbucket.org/JesusFreke/smali/downloads ) and shifted them to a folder to work in. I have extracted the odex files from the Nexus 5X
and extracted the framework for baksmali to work with
I then moved all the files to the folder containing the baksmali.jar file and ran the command to extra all the smali files
Now I was wondering, How do you build them into the apk? I have tried a few things but they just cause the SystemUI to crash once booted.
If anyone can tell me how to fix this, then please tell me.
Click to expand...
Click to collapse
I figured out how to do this so it doesn't matter anymore.
If anyone wants to know you just need to make a small folder in the apk and don't the files to it.