📱

Run Android Studio on Ubuntu Smartphone

Sep 15, 2024

Installing Ubuntu and Android Studio on Smartphone

Overview

  • IDE: Integrated Development Environment to create Android OS using Kotlin or Java.
  • Goal: Run Android Studio on a smartphone using Ubuntu.

Initial Setup

  1. Install Ubuntu

    • Open Termux app.
    • Type command: pkg update and press enter.
    • Respond with Y as prompted to update packages.
    • Type command: pkg upgrade to install latest packages.
  2. Install Ubuntu OS

    • Command available in video description or comments.
    • Installation may take about 1 hour.
    • Select language (English) and keyboard layout.
    • Set a password for Ubuntu and VNC server (example given: "YouTube").

Connecting to VNC Server

  • Use VNC server app:
    • Add a new connection: localhost:1
    • Name the connection (e.g. "Ubuntu OS").
    • Enter previously set password.

Update Ubuntu

  • Open terminal in Ubuntu and run:
    • apk update

Install Java Development Kit (JDK)

  • Type command:
    • sudo apk install default-jdk
  • Provide the super user password (Ubuntu).

Download and Install Android Studio

  1. Download Android Studio

    • Search for Android Studio download link in Firefox.
    • Accept terms and conditions and download "Android Studio Flamingo" (around 1GB).
    • If already downloaded, skip this step.
  2. Move and Extract Android Studio

    • Open terminal and navigate to downloads:
      • cd downloads
    • Move downloaded file to /opt folder:
      • mv AndroidStudio-* /opt
    • Extract the file:
      • tar -xzf AndroidStudio-*
    • Navigate to bin directory:
      • cd /opt/AndroidStudio/bin
  3. Create Shortcut for Android Studio

    • Create a shortcut using:
      • echo '#!/bin/bash /opt/AndroidStudio/bin/studio.sh' > android-studio
    • Make shortcut executable:
      • chmod +x android-studio

Launch Android Studio

  • Run Android Studio by typing:
    • ./android-studio
  • Follow setup wizard to install JDK and additional SDKs.
  • You can create a new Android Studio project after setup.

Conclusion

  • This setup allows full Android development environment on a smartphone.
  • For assistance, contact via Instagram (link in description).

Reminder

  • If commands are difficult, pause the video and type them out.
  • This video is fast-paced to save time; keep up by pausing as needed.