Mike Szczys · May 5, 2013 at 10:00 pm

Decompile, Recompile, and Sign APKs by Example

Last month, we saw a new tool that made it painless to edit the contents of Classes.dex. If you were drawn in by that prospect but couldn’t quite get the pieces to work, I think you’ll appreciate following the example that XDA Recognized Themer/Contributor Rizal Lovins put together. He takes one step back to look at the bigger picture, giving a start-to-finish walkthrough for decompiling, editing, recompiling, and signing an APK file. The necessary tools are pretty much the same (Windows, Java, Android SDK, Apktool, and a text editor) so that you may pick up where you left off with your smali and Baksmali editing experiments.

To use Apktool to decompile an APK, you need to also have the support packages it uses (ie: framework-res.apk). After issuing a few commands, Apktool will spit out the files hidden within and it’s time to start editing. Rizal then goes on to show how to package everything back up and resign the edited app. Check out the original thread for full details.

The biggest benefit of publishing guides like this one is that the community can learn and improve upon them. XDA Recognized Themer Ibanez7 did just that. His thread, which mentions Rizal’s work as a reference, demonstrates how to use the same techniques to change the font color and edit the activity title bar of an app.

 

 


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

Mike Szczys

szczys is an editor on XDA-Developers, the largest community for Android users. Mike Szczys is a professional musician but spends all his free time working with hobby electronics. As Contributing Editor for Hackaday.com he became interested in Android as some of the early hardware hacks started popping up on the Internet. What followed was a gradually rising addiction to all things Android. View szczys's posts and articles here.
Brian Young · Aug 2, 2015 at 09:05 pm · 2 comments

Galaxy S6 & Edge get €100 Price Cut—New Models Incoming

Samsung has dropped the price of both the Galaxy S6 and S6 Edge by €100, making the current retail price of these phones €599 and €699, respectively. Though no new prices have been announced stateside, a cut is expected soon. (more…)

XDA NEWS
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 · 3 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