Skip to content
Coding Fanatic
  • Android Development
  • News and Reviews
  • Road2Pro
  • Tutorials
  • Services
  • About

How to Install Android Studio Linux Style

  • September 8, 2016April 11, 2020
  • by Richard Clarke

As a Linux enthusiast and a newcomer to Android development, I am excited to present you with a tutorial on setting up the best Android Dev tool on the best operating system, Linux Mint!

To be fair, I don’t know of any other Android Development tools. But I am in love with Linux Mint. That part is 100% true

This tutorial will span 3 parts: Installing the Java JDK, Installing Android Studio, and setting up to create an application. Click images to see them in their full size during the tutorial. Let’s start!

PART 1: Java JDK Installation

  1. First remove your openJDK installation so that you can install the appropriate version of Java for Android Development.
      • Open the Terminal
      • Type su to become a superuser
      • Enter your password at the prompt
      • Type: sudo apt-get update && apt-get remove openjdk*
      • Type Y for yes
      • The installation process will now take place.

    screenshot-from-2016-09-07-205429

  2. Download the Oracle JDK here.
      • Be sure to select the Linux version containing a tar.gz extension for this tutorial.
      • Accept the License Agreement before downloading
      • Remember, select x86 if your computer has a 32-bit CPU and x64 for a 64-bit CPU otherwise you will not be able to install the Oracle JDK properly!

    screenshot-from-2016-09-07-210059

  3. In the Terminal window, navigate to your downloaded file using the cd command
    • cd Downloads/ 
  4. Using the terminal, extract the necessary files from the downloaded file using the tar command.
    • tar -zxvf jdk-8u101-linux-x64.tar.gz 
  5. Since we typed the su command to become a superuser in the start of the tutorial, we have the permissions necessary for creating directories for the Oracle JDK in the next few steps. Create a directory in the /opt directory where your java jdk will be stored and referenced later on
    • mkdir -p /opt/java 
  6. Move your jdk folder to the directory you created in Step 5
    • mv jdk1.8.0_101/ /opt/java/ 
  7. The next two commands will make your new JDK the system default. When we install Android Studio, it will automatically recognize this installation.
    • sudo update-alternatives –install “/usr/bin/java” “java” “/opt/java/jdk1.8.0_101/bin/java”
    • sudo update-alternatives –set java /opt/java/jdk1.8.0_101/bin/java 
  8. For the final step, test the installation with this command to ensure everything installed properly
    • java -version

Part 1 is finally complete! Take a breath of fresh air, stretch, and get ready for Part 2! To return to your regular user privileges, type the command exit into the terminal. Switch back to root at any time by typing su and entering your password at the prompt.

PART 2: Downloading the Android Studio Repository

  1. Once again, we will be returning to the Terminal. Fire it up and enter the following command to download the Android Studio repository. Enter your password if it prompts you to do so.
    • sudo apt-add-repository ppa:paolorotolo/android-studio
    • enter your password 
  2. When that is finished, update all of your repositories (including the freshly downloaded Android Studio repository) with the following command:
    • sudo apt-get update 
  3. Finally, use this last command to install the Android Studio application
    • sudo apt-get install android-studio 
  4. When this is done, log out and log back in to see the changes complete. (I recommend restarting, but logging out should suffice)

Part 2 complete! Boy this process gets easier as you work through it.

PART 3: Setting up an Android Application

  1. This last part is very straightforward. Startup Android Studio and allow the project files to load completely.
    • Click “Start a new Android Studio project”. 
  2. The Application Name is the name your app will have in the Play Store. The Company Domain is your website. Fill this field with the address of your website or leave it as the example provided. Click Next. 
  3. Select “Phone and Tablet”. I recommend selecting Android 4.0.3 IceCreamSandwich or higher as your Minimum SDK to ensure your application is compatible with the most devices while maintaining the highest speed. Click Next 
  4. Select “Basic Activity” as your Activity. Click Next, and Finish on the next screen as well.

Congratulations! You have now successfully installed Android Studio and are well on your way to becoming an Android Developer! Thanks for checking out the tutorial, let me know if you have any questions comments or concerns in the box below!

Join the mailing list to see updates like this every week!
Coding Fanatic

Follow me on Twitter @rclarkecf for more content daily!

Related

Should I Make Friends At My Job?
A Tale of Software Installations and the Lack Thereof
Richard Clarke
Richard is currently a developer using Java and Android Studio to build custom applications for Android. Richard tutored in mathematics at Montgomery College, and worked in Information Technology before entering the Software Development industry as a Quality Engineer.
Android Android Studio Installation linux Linux Mint Mint Tutorial

Related articles

Your New Favorite Stopwatch App!…
Two for Two BABY! 7…
…But the App is for…
Play Store Blues – 5…
Top 4 Tips for Android…
No Dice – 3 of…

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Join the mailing list!

This field is required.

Check your inbox or spam folder to confirm your subscription.

Follow me on social media!

  • GitHub
  • YouTube
  • X
  • Instagram
  • LinkedIn
My Tweets

Join the mailing list!

This field is required.

Check your inbox or spam folder to confirm your subscription.

Follow me on social media!

  • X
  • GitHub
  • LinkedIn
  • YouTube

Archives

Theme by Colorlib Powered by WordPress