Platform: Ubuntu 14.04 x64
1. Install JDK from Oracle (JDK 7 or above)
http://askubuntu.com/questions/521145/how-to-install-oracle-java-on-ubuntu-14-04
2. Setup environment variables and JAVA_HOME
Create a file /etc/profile.d/oraclejdk.sh with the following content (adapt the paths to reflect the path where you stored your JDK):
export J2SDKDIR=/usr/lib/jvm/oracle_jdk8
export J2REDIR=/usr/lib/jvm/oracle_jdk8/jre
export PATH=$PATH:/usr/lib/jvm/oracle_jdk8/bin:/usr/lib/jvm/oracle_jdk8/db/bin:/usr/lib/jvm/oracle_jdk8/jre/bin
export JAVA_HOME=/usr/lib/jvm/oracle_jdk8
export DERBY_HOME=/usr/lib/jvm/oracle_jdk8/db
3. Execute
[android SDK root]/tools/android sdk and add necessary packages
http://developer.android.com/sdk/installing/adding-packages.html
4. Download and Install Android Studio
http://developer.android.com/sdk/installing/index.html?pkg=studio
Android Studio
INSTALLATION INSTRUCTIONS
===============================================================================
Linux Installation Instructions
------------------------------------------------------------------------------
1. Unpack the Android Studio distribution archive that you downloaded to
where you wish to install the program. We will refer to this destination
location as your {installation home} below.
2. Open a console and cd into "{installation home}/bin" and type:
./studio.sh
to start the application.
3. [OPTIONAL] Add the "{installation home}/bin" to your PATH environmental
variable so that you may start Android Studio from any directory.
4. [OPTIONAL] To adjust the value of JVM heap size open android studio.vmoptions
(android studio64.vmoptions for 64-bit JDK), and modify the -Xms and -Xmx parameters.
[OPTIONAL] Changing location of "config" and "system" directory
------------------------------------------------------------------------------
By default Android Studio stores all your settings under ~/.AndroidStudio/config directory
and stores data cache under ~/.AndroidStudio/system directory.
If you want to change these settings,
1. Open a console and cd into "{installation home}/bin"
2. Open file "idea.properties" in an editor. You should find strings like
idea.system.path=~/.AndroidStudio/system
and
idea.config.path=~/.AndroidStudio/config
and change them.
3. Note that we recommend to store data cache ("system" directory) at a disk
with at least 1G bytes free space
Enjoy!
-Android Studio Development Team
5. First time execute Android Studio, you may encounter a problem.
"Unable to run mksdcard SDK tool."
The following solution works for me
http://askubuntu.com/questions/147400/problems-with-eclipse-and-android-sdk
sudo apt-get install -y libc6:i386 libgcc1:i386 libstdc++6:i386 libz1:i386
6. Remember to change the Android SDK path in Android Studio.
Or it will download the SDK again under ~/Android.
http://stackoverflow.com/questions/16581752/android-studio-how-to-change-android-sdk-path
7. How to create the Android Studio shortcut on Launcher
http://askubuntu.com/questions/298857/how-to-add-android-studio-to-the-launcher