Tomek Kondrat · Dec 18, 2013 at 08:30 pm

GetJava Helps You Convert APKs into Java Projects

Android is an operating system that uses a lot of programming languages. The most common languages are Java (or Android Java if you prefer), C, XML, Bash, as well as a few more. Android applications can be decompiled by APKTool and a few similar tools, and their output is Smali. I know that many of you will disagree with me, but Smali is quite complicated language—much more than Java.

There are two tools that can convert Smali back to Java: Dex2Jar and JAD. They are pretty hard to use, though, and need some experience to use them properly. Luckily, XDA Recognized Developer broodplank1337 created a simple bash script, that does all the work for us. This script can get all necessary dependencies, as well as get the Java code straight from APK. It works on Linux only, but I’m quite sure that can be used on non UNIX-like systems like Windows with Cygwin. The developer recommends that you put the file in ~/bin and make it executable. Further instructions are available in the thread.

Sometimes scripts can make life a lot easier. If you are interested in the project, make your way to the original thread to get more information and learn how to convert assembler code into Java.

Note: Tools like this should be used for educational purposes. “Borrowing” code from applications (paid or free) is unethical and should not take place. They are closed source for a reason. Keep that in mind.


_________
Want something on the XDA Portal? Send us a tip!

Tomek Kondrat

eagleeyetom is an editor on XDA-Developers, the largest community for Android users. Tomek is the only Polish moderator on XDA Developers. He graduated from the University of Warmia and Mazury in Olsztyn with a degree in journalism and public communication in 2013. He's a big fan of football (not hand egg), post rock and cooking. A total addict of mobile technology, especially Android. Currently flashes dozens of custom ROMs on his OPO. View eagleeyetom's posts and articles here.
Mario Tomás Serrafero · Aug 2, 2015 at 11:33 am · 1 comment

Sunday Debate: How Can We Get a No-Compromise Phone?

Join us in a fun Sunday Debate on Compromises. Come with your opinions and feel free to read some of our thoughts, then pick your side or play devil’s advocate to get your voice heard and engage in friendly discussion. You can read our food-for-thought or jump straight into the fray below!     Getting an upgrade is a big deal to us power users: it’s our little Android Christmas, where after a long time (for plenty of us, at least)...

XDA NEWS
Mario Tomás Serrafero · Aug 1, 2015 at 03:54 pm · 2 comments

PSA: You Can Optimize Your Note 4’s Recents Menu & RAM

The Note 4 never had the fastest Recents Menu, and despite its 3GB of RAM, its app-holding capabilities only got worse on Lollipop. The infamous RAM bug that plagued the S6 is indeed an annoyance on the Note 4's 5.0.X ROMs. Rumors of an update to fix all of this were confirmed with the first reports of the 5.1.1 update for the Russian Note 4, which seemingly improved the Recents Menu and RAM management. But it'll be a long time...

XDA NEWS
Mario Tomás Serrafero · Aug 1, 2015 at 01:33 pm · 1 comment

XDA Picks: Best Apps of the Week (July 25 – Aug 1)

Apps are at the front and center of any smartphone experience, and with over a million apps on the Google Play Store and new apps being submitted to our forums every day, staying up to date on the latest apps and games can be a hassle. At XDA we don’t discriminate apps - if it’s interesting, innovative, original or useful, we mention them. The XDA Portal Team loves apps too, and here are our top picks for this week.  ...

XDA NEWS