tilc / AndroidSDK Setup (Linux)

Last active 4 hours ago

Like 0

Instructions for setup of android development on Linux with AndroidCLI

android_sdk_setup_linux.md Raw

AndroidSDK Setup (Linux)

Install Android CLI

  • First download and install the latest version of android cli
$ curl -fsSL https://dl.google.com/android/cli/latest/linux_x86_64/install.sh | bash 

Install Android Debug Bridge (adb)

  • This tool allows you to communicate with your android device.
  • When a bridge is established you can install you application onto the device
$ sudo apt update
$ sudo apt install adb
  • Run with
$ adb start-server

Emulation

  • First you have to create an emulator
$ android emulator create
  • Run with:
$ ~/Android/Sdk/emulator/emulator @medium_phone -no-snapshot -gpu swiftshader_indirect

Gradle

  • This is the used android application build system
  • In your project create the gradlew build script
  • The first time you run the script gradle will setup everything you need
  • To build and install your application on the connected device run:
$ ./gradlew installDebug

References