Installing Android Studio in Ubuntu 13.04
Posted on Monday, May 20, 2013
Go to http://developer.android.com/sdk/installing/studio.html and download Android studio for linux. It will download a tar file in your Downloads folder. Once downloaded, open Nautilus, navigate to Downloads folder, right click in android-studio-bundle-130.677228-linux and select "extract here".
Now you have a new folder named "android studio". Move this folder to your Home folder.
To run the IDE, open the terminal and type:
cd android-studio/binIf you are on Ubuntu default installation, using OpenJava, you will see this warning:
./studio.sh

If you press Enter Android studio will start with this window:

Troubleshooting.
Installing Oracle Java SDK:There are two ways for installing Oracle Java SDK.
First method.
First the easy one. Open the console and type:sudo add-apt-repository ppa:webupd8team/javaOk, now let's check the java version installed. Type:
sudo apt-get update
sudo apt-get install oracle-java7-installer
java -versionand you should see something like:
java version "1.7.0_21"
Java(TM) SE Runtime Environment (build 1.7.0_21-b11)
Java HotSpot(TM) 64-Bit Server VM (build 23.21-b01, mixed mode)
Second method:
Go to http://www.oracle.com/technetwork/es/java/javase/downloads/index.html and download Java JDK. Be sure to download the tar.gz corresponding to your architecture (Linuxx86 or Linuxx64).Uncompress the file:
tar -xvf jdk-7u21-linux-i586.tar.gz (32bit)Now let's move the uncompressed folder to /usr/lib
tar -xvf jdk-7u21-linux-x64.tar.gz (64bit)
sudo mkdir -p /usr/lib/jvmNow run in terminal:
sudo mv ./jdk1.7.0_21 /usr/lib/jvm/jdk1.7.0
sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.7.0/bin/java" 1Change ownership and permissions:
sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.7.0/bin/javac" 1
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/jdk1.7.0/bin/javaws" 1
sudo chmod a+x /usr/bin/javarun:
sudo chmod a+x /usr/bin/javac
sudo chmod a+x /usr/bin/javaws
sudo chown -R root:root /usr/lib/jvm/jdk1.7.0
sudo update-alternatives --config javaand choose the option corresponding to /usr/lib/jvm/jdk1.7.0/bin/java
do the same for
sudo update-alternatives --config javacNow check the version with
sudo update-alternatives --config javaws
java -version
Discussion