0

I'm trying to open various .apk files in Eclipse for the purpose of viewing the source code. I'm developing for Google Glass, and I need to see how the code of the third party software I downloaded is executed. I'm able to view the code using JD-GUI and dex2jar, but I can't compile and run it on Glass. Whenever I try to import the existing code in Eclipse, it is grayed out and I can't select it: even the Google made samples like the compass and charades apps. I am new to this, so perhaps I've missed a step or something of the sort. I'd greatly appreciate any help or advice on the matter!

Thanks, Jordan

JasonMArcher
  • 14,195
  • 22
  • 56
  • 52
JCoppert
  • 3
  • 1
  • 3

1 Answers1

1

Generally you don't access the source code via the jar/apk. Those are compiled, or translated, from the source code to the code that Glass/Android actually runs. Because of this, you're probably not going to be able to view the actual source code for these projects.

If you want to get the source code (and import it into Eclipse) for the Google Projects, go to https://github.com/googleglass/?query=gdk, select one of the applications, and click the "Download ZIP" button. This will give you a .zip of the source code.

If you're feeling really brave and want to learn even more, try cloning the repository with git. The git website has a great tutorial/introduction at http://git-scm.com/book/en/Getting-Started-Git-Basics.

Jessie A. Morris
  • 2,267
  • 21
  • 23