When I first attempted to install the SDK, I found tutorials that only had bits and pieces about the whole procedure. A lot of Google searches and hours of eye strain. I wanted to write a solid tutorial, but instead of publishing it in a personal blog, I chose to publish it here on xda-developers. This is the definite forum to come to if you are interested in Android/G1/HTC Dream development or costumization. I wrote this to make the enlarge the knowledge of this community.
!! THIS TUTORIAL IS FOR THE LATEST UBUNTU RELEASE: JAUNTY JACKALOPE 9.04 !!
!!START -------------------------------------- Optional Preparation --------------------------------------
This applies if you -
And your machine -
This procedure will make things easier during installation of the SDK and in the long run. Hopefully you've read about partitions. If you are dualbooting, please read this first to get an idea of what you're doing.
!!START -------------------------------------- Installing Android SDK --------------------------------------
Installing the SDK is the easiest of all.
!!START -------------------------------------- ADB + FASTBOOT --------------------------------------
The Android Debug Bridge (adb) is one of the tools that will help you the most when you run into flashing problems or running shell commands directly from your machine. UDEV will not recognize your G1 out of the box, but we will configure it with some rules so it can connect.
We will work with /AndroidSDK as the location of your sdk. If this is not your setup, I think you're smart enough to figure it out.
Editing .bashrc file to use tools from /AndroidSDK/tools/ directory -
Setting up UDEV to recognize HTC Device -
Setting up fastboot -
!! THIS TUTORIAL IS FOR THE LATEST UBUNTU RELEASE: JAUNTY JACKALOPE 9.04 !!
!!START -------------------------------------- Optional Preparation --------------------------------------
This applies if you -
- Are interested in installing Ubuntu for the first time.
- Are/will be reinstalling Ubuntu from scratch.
- Want to keep your SDK installation easy to reach.
- Want to keep things nice and clean.
- Has a second hard drive.
- Has free space for another small partition.
- While installing Ubuntu and on the Prepare Disk Space screen (partition editor), select "Specify partitions manually (Advanced)"
- On the Create Partition dialog, select the following options:
- Type for the new partition: Primaryor Logical if you're dualbooting and know what you are doing.
- New partition size in megabytes: 5120MB (5GB) might work. BUT:It should be noted that if you ever plan on compiling kernels and/or cupcake ROM's you will NEED ubuntu8.04. You'll also need at least 10GB.
- Location for the new partition: Beginning
- Use as: Ext4 or Ext3Filesystem doesn't matter. (?)
- Mount point: /AndroidSDKEnter this manually
- Type for the new partition: Primary
- Complete Ubuntu installation as usual.
-------------------------------------- Optional Preparation -------------------------------------- END!!
You will now install the SDK.
!!START -------------------------------------- Installing Android SDK --------------------------------------
Installing the SDK is the easiest of all.
- Download the SDK.
- Right-click and select Extract Here.
- Move the contents of the android-sdk-linux_x86-1.5_r3 directory to your desired location.If you followed Optional Installation, move the contents to your /AndroidSDK directory in the root of your filesystem.
- Close directory window.
-------------------------------------- Installing Android SDK -------------------------------------- END!!
You will now set up your bashrc file and UDEV to recognize your HTC Device.
!!START -------------------------------------- ADB + FASTBOOT --------------------------------------
The Android Debug Bridge (adb) is one of the tools that will help you the most when you run into flashing problems or running shell commands directly from your machine. UDEV will not recognize your G1 out of the box, but we will configure it with some rules so it can connect.
We will work with /AndroidSDK as the location of your sdk. If this is not your setup, I think you're smart enough to figure it out.
Editing .bashrc file to use tools from /AndroidSDK/tools/ directory -
- Go to your home folder.Example: /home/wddglr/
- Press Control + H to view hidden files.
- Look for your .bashrc file and double click to open it with gedit.
- Add the following lines to the top of the file:
Code:
#AndroidDev PATH export PATH=${PATH}:/AndroidSDK/tools
IMPORTANT NOTEThis is the way that I have my .bashrc file setup. For those having problems with it not recognizing the adb as a command try this...
Code:export PATH=$PATH:/AndroidSDK/tools
Setting up UDEV to recognize HTC Device -
- Type the following into a terminal (Applications > Accessories > Terminal):
Code:
gksudo gedit /etc/udev/rules.d/51-android.rules
- Now add the following line to the blank file:
Code:
SUBSYSTEM=="usb", SYSFS{idVendor}=="0bb4", MODE="0666"
- Click save and close.
- To restart udev, open up a terminal and enter:
Code:
sudo /etc/init.d/udev restart
Setting up fastboot -
- Download this fastboot binary from http://android-dls.com.130.4 KB [http://android-dls.com/files/linux/fastboot]
- Once downloaded to your desktop, right click and select Properties.
- Navigate to the Permissions tab and configure the following option:Execute: [√] Allow executing file as program
- Click Close.
- Move the fastboot bianary to your /AndroidSDK/tools/ directory.
- Reboot.
-------------------------------------- ADB + FASTBOOT -------------------------------------- END!!
Now you can use adb and fastboot directly from any terminal. If you chose to do the Optional Preparation, you can now save your Eclipse Workspace and your downloaded/custom ROMs/Themes in this new /AndroidSDK directory keeping things easier to reach and safe from evil disk errors or other mishaps!!! :O
If you are having problems, send me a PM. I will be happy to help.
Last edited: