Friday, November 26, 2010

Setting up Android Development Environment with Eclipse

I've done set up a fifth computer with the Android Dev environment and every time it's a gorram struggle. I hate setting up workstations! So here I am, finally conceding to the idea that there will never be a last and final time for the most tedious, time consuming, and confusing chores.

1) Download Eclipse IDE for Java Developers 3.5 (Galileo). The newer version 3.6 Helios is not supported by android. Galileo comes as a zip file, no install necessary. Unzip somewhere you will remember, and make shortcuts to your desktop/task bar/whatever.
http://www.eclipse.org/downloads/packages/eclipse-ide-java-developers/galileor

2) Download JDK/JRE v.6 (or the new v.7). Follow the install. You will need a login username and password for Sun Microsystems. (*Optional: After install, find the jdk folder, and copy the "jre" file into your eclipse folder. I don't know if this is the correct way to do this, but it works for me. Particularly useful if you downloaded the Android SDK as a zip rather than the installer.)
http://www.oracle.com/technetwork/java/javase/downloads/index.html

3) Download Android SDK. This can also come as a zip file but also includes an installer which I will recommend, because the installer will "link" the Android SDK to the JDK. Whatever that means. But because of this linking thing, the JDK has to be fully installed first in order to run.
http://developer.android.com/sdk/index.html

4) Add SDK Platform. After the installer from step 3 finishes, start the SDK program. Start checking off stuff to add. You need at least ONE platform to begin developing in android. You will need to download all the versions you plan on testing on. Be sure to add packages in small groups, if you try to do it all at once it crashes or never finishes.

5) "Download"/Install/Configure ADT plugin. Finish downloading the SDK in step 4 before attempting this. Adding the ADT to Eclipse requires use of the "Adding new software" option from the Help menu. Its awful and feels wrong. Instructions at the link below. Be sure to follow the steps for downloading AND configuring the ADT plugin!



6) Create an AVD (Android Virtual Device.)  This is the emulator. I set the target to Android 2.2 - API Level 8, and the skin to WVGA854
http://developer.android.com/guide/developing/tools/avd.html#creating

Resources:
http://developer.android.com/sdk/requirements.html
http://developer.android.com/sdk/installing.html

No comments:

Post a Comment