Reputation:
is there any possible to convert dex2.jar file into classes.dex again without compile.here i sucessfully coverted the apk file to normal java source code using reverse enginerring process.
Upvotes: 3
Views: 5084
Reputation: 1214
If your goal is to modify the application, do not modify it at the java level. This will fail for all but the most trivial of projects! Decompilers such as dex2jar
, jeb
, and enjarify
are too low fidelity to trust not to alter behavior (read: break the code).
At best, use a decompiler (like dex2jar
) to view the java and understand what you want to change. Then, get the smali disassembly using baksmali
and make your changes at the smali level. Finally, use the smali
tool to compile it back into a dex
file.
It's more difficult, but it's much more likely to be successful. There are lots of guides online for how to modify smali code. It will take a little more time, but it's really the only way.
Upvotes: 1
Reputation: 7672
The 'dx' tool will let you do this.
dx inputfile.jar --output classes.dex
Why don't you want to just run it through the standard compiler, again?
Upvotes: 0