diff options
Diffstat (limited to '_site_build/_posts/2012-08-01-installing-the-android-sdk-on-ubuntu.markdown')
| -rw-r--r-- | _site_build/_posts/2012-08-01-installing-the-android-sdk-on-ubuntu.markdown | 81 |
1 files changed, 0 insertions, 81 deletions
diff --git a/_site_build/_posts/2012-08-01-installing-the-android-sdk-on-ubuntu.markdown b/_site_build/_posts/2012-08-01-installing-the-android-sdk-on-ubuntu.markdown deleted file mode 100644 index 19d5c3a..0000000 --- a/_site_build/_posts/2012-08-01-installing-the-android-sdk-on-ubuntu.markdown +++ /dev/null @@ -1,81 +0,0 @@ ---- -layout: post -title: Installing the Android SDK on Ubuntu -author: David T. Sadler -description: This guide will show you how to install the Android SDK and the Eclipse IDE on Ubuntu. -categories: ["Android","Ubuntu"] -robots: follow, noodp, noydir, noarchive -comments: false -google_plus: false -twitter_share: false -facebook_like: false -published: true -licensed: true ---- -This guide will take you through the nessecary steps for installing the Android SDK on Ubuntu. You will also install the Eclipse IDE which you will use to develop a simple "Hello world" application that will then be ran on either the Android emulator or an actual Android device. - -As this guide is quite long I have broken it down into the following sections. - -* [Getting started.](#start) -* [The Android SDK.](#sdk) -* [The Eclipse IDE.](#ide) -* [The Android Development Toolkit (ADT) plugin for Eclipse.](#adt) -* [Creating an application.](#application) -* [Running the application on the Emulator.](#emulator) -* [Running the application on an Android device.](#device) - -<h2 id="start">Getting started.</h2> - -For this guide I used Ubuntu 12.04 (Precise Pangolin). The instructions should work on other versions of Ubuntu but keep in mind that I won't have tested this. - -Before getting down to the business of installing the SDK you must ensure that the following have been installed on your system. - -<dl> - <dt>Java Development Kit (JDK)</dt> - <dd><p>Provides tools such as the Java compiler that allow us to develop Java applications.</p></dd> - <dt>Java Runtime Enviroment (JRE)</dt> - <dd><p>Provides an enviroment so that Java programs, such as Eclipse, can run on your system.</dd> - <dt>Apache Ant</dt> - <dd><p>A Java tool for automating software build processes. Allows you to build Android applications outside of an IDE. While it won't be used in this guide you will find it useful if you move onto developing large Android applications.</p></dd> -</dl> - -Installation is as simple as entering the following commands. - -{% highlight bash %} -sudo apt-get update -sudo apt-get install ant default-jdk default-jre -y -{% endhighlight %} - -If you are developing on a 64-bit system there is an extra step that you will need to do. According to the SDK <a href="http://developer.android.com/sdk/index.html" rel="external nofollow" target="_blank" title="Go to the Android SDK website">website</a> you must be capable of running 32-bit applications. On 64-bit versions of Ubuntu 12.04 this is done with the command below. - -{% highlight bash %} -sudo apt-get install ia32-libs-multiarch -{% endhighlight %} - -<h2 id="sdk">The Android SDK.</h2> - -Installing the SDK is done by downloading the archived Android SDK Starter Package that Google provides. This is not the complete SDK enviroment as it only includes the core SDK tools. You will use these tools to download the rest of the SDK. Since it is very likely that the package has been updated since this guide was written you should check the <a href="http://developer.android.com/sdk/index.html" rel="external nofollow" target="_blank" title="Go to the Android SDK website">website</a> for the current version number. - -For this guide I will show you how to install the SDK for a single user on your system. There are other ways of installing but for this guide I want to keep things simple. We will do this by downloading and installing the SDK into your home directory. - -The first thing we need to do is to get the starter package and unpack it. - -{% highlight bash %} -cd ~ -wget http://dl.google.com/android/android-sdk_r20.0.1-linux.tgz -tar -xzvf android-sdk_r20.0.1-linux.tgz -rm android-sdk_r20.0.1-linux.tgz -{% endhighlight %} - -You will now have a directory called `android-sdk-linux` located within your home directory. The core SDK tools are located in sub-directories called `tools` and `platform-tools`. To make it easier to access these tools from the command line you can add their locations to your PATH environment variable. - -{% highlight bash %} -echo 'PATH=$PATH:$HOME/android-sdk-linux/tools:$HOME/android-sdk-linux/platform-tools' >> $HOME/.bashrc -source ~/.bashrc -{% endhighlight %} - -<h2 id="ide">The Eclipse IDE.</h2> -<h2 id="adt">The Android Development Toolkit (ADT) plugin for Eclipse.</h2> -<h2 id="application">Creating an application.</h2> -<h2 id="emulator">Running the application on the Emulator.</h2> -<h2 id="device">Running the application on an Android device.</h2> |
